feat(GODT-2714): Set Configuration Status to Failure and send Recovery event when issue is solved.

This commit is contained in:
Romain LE JEUNE
2023-06-28 15:26:41 +02:00
parent fa4c0ec823
commit 720f662afe
9 changed files with 118 additions and 18 deletions

View File

@ -297,10 +297,12 @@ func (bridge *Bridge) SetColorScheme(colorScheme string) error {
// Note: it does not clear the keychain. The only entry in the keychain is the vault password,
// which we need at next startup to decrypt the vault.
func (bridge *Bridge) FactoryReset(ctx context.Context) {
telemetry := bridge.IsTelemetryAvailable()
// Delete all the users.
safe.Lock(func() {
for _, user := range bridge.users {
bridge.logoutUser(ctx, user, true, true)
bridge.logoutUser(ctx, user, true, true, telemetry)
}
}, bridge.usersLock)