Skip to content

Commit e109688

Browse files
committed
refactor: ccm should commit changes
1 parent 978a4d1 commit e109688

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

src/stateMachines/activation.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -786,6 +786,7 @@ describe('Activation State Machine', () => {
786786
'INIT_TLS_TUNNEL',
787787
'GET_GENERAL_SETTINGS',
788788
'SETUP',
789+
'COMMIT_CHANGES',
789790
'DELAYED_TRANSITION',
790791
'SAVE_DEVICE_TO_SECRET_PROVIDER',
791792
'SAVE_DEVICE_TO_MPS',
@@ -2013,6 +2014,7 @@ describe('Activation State Machine', () => {
20132014
'INIT_TLS_TUNNEL',
20142015
'GET_GENERAL_SETTINGS',
20152016
'SETUP',
2017+
'COMMIT_CHANGES',
20162018
'DELAYED_TRANSITION',
20172019
'SAVE_DEVICE_TO_SECRET_PROVIDER',
20182020
'SAVE_DEVICE_TO_MPS',

src/stateMachines/activation.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1267,6 +1267,11 @@ export class Activation {
12671267
guard: 'isSHBCCMComplete',
12681268
actions: [assign({ message: ({ event }) => event.output })],
12691269
target: 'SET_MEBX_PASSWORD'
1270+
},
1271+
{
1272+
// Regular CCM commit — proceed to delayed transition
1273+
actions: [assign({ message: ({ event }) => event.output })],
1274+
target: 'DELAYED_TRANSITION'
12701275
}
12711276
],
12721277
onError: [
@@ -1304,7 +1309,7 @@ export class Activation {
13041309
},
13051310
'Set activation status'
13061311
],
1307-
target: 'DELAYED_TRANSITION'
1312+
target: 'COMMIT_CHANGES'
13081313
},
13091314
{
13101315
guard: 'isDeviceClientModeActivated',
@@ -1314,7 +1319,7 @@ export class Activation {
13141319
},
13151320
'Set activation status'
13161321
],
1317-
target: 'DELAYED_TRANSITION'
1322+
target: 'COMMIT_CHANGES'
13181323
},
13191324
{
13201325
actions: assign({ errorMessage: 'Failed to activate in client control mode.' }),

0 commit comments

Comments
 (0)