fix: activate old background while on page

This commit is contained in:
sethburkart123
2024-11-13 09:34:34 +11:00
parent 0bb4d89570
commit 5dc3526711
+2
View File
@@ -2,6 +2,7 @@ import browser from 'webextension-polyfill';
import base64ToBlob from './base64ToBlob';
import { openDatabase, writeData } from '@/interface/hooks/BackgroundDataLoader';
import { backgroundUpdates } from '@/interface/hooks/BackgroundUpdates';
import { loadBackground } from '@/seqta/ui/ImageBackgrounds';
const MIGRATION_STATE_KEY = 'background_migration_state';
@@ -54,6 +55,7 @@ export const migrateBackgrounds = async (): Promise<void> => {
if (isSelected) {
localStorage.setItem('selectedBackground', id);
await loadBackground();
}
migrationState.lastProcessedId = id;