Skip to content

Commit a37d6d7

Browse files
committed
fix: update dataStatus during identity restoration process
- Changed the dataStatus from ACTIVE to NOTINITIALIZED when restoring identities to better reflect their state. - This adjustment ensures that the identity's status is accurately represented post-restoration.
1 parent 22e4e30 commit a37d6d7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

apps/api/src/core/backends/backends.service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -361,13 +361,13 @@ export class BackendsService extends AbstractQueueProcessor {
361361
message: `Identity ${key} not found`,
362362
});
363363
}
364-
364+
365365
const targetState = identity.lastBackendSync ? IdentityState.TO_SYNC : IdentityState.TO_CREATE;
366366
await this.identitiesService.model.findByIdAndUpdate(key, {
367367
$set: {
368368
state: targetState,
369369
deletedFlag: false,
370-
dataStatus: DataStatusEnum.ACTIVE,
370+
dataStatus: DataStatusEnum.NOTINITIALIZED,
371371
},
372372
});
373373
result[identity._id] = { restored: true, state: targetState };

0 commit comments

Comments
 (0)