fix(app): write the first voice session restore snapshot on startup (#1974)

This commit is contained in:
Hampus authored and GitHub committed 2026-08-24 12:56:04 +02:00
1 parent fdd12194b1
commit a0d4a33fd4
1 file changed
+2 -2
@@ -62,10 +62,10 @@ export function saveCurrentVoiceSessionRestoreSnapshot(): void {
} }
export function createVoiceSessionRestoreSync(): VoiceSessionRestoreSyncHandle { export function createVoiceSessionRestoreSync(): VoiceSessionRestoreSyncHandle {
let previousState = readVoiceSessionRestoreSyncState(); let previousState: VoiceSessionRestoreSyncState | null = null;
const syncVoiceSessionRestore = () => { const syncVoiceSessionRestore = () => {
const currentState = readVoiceSessionRestoreSyncState(); const currentState = readVoiceSessionRestoreSyncState();
if (areVoiceSessionRestoreSyncStatesEqual(previousState, currentState)) { if (previousState !== null && areVoiceSessionRestoreSyncStatesEqual(previousState, currentState)) {
return; return;
} }
previousState = currentState; previousState = currentState;