diff --git a/packages/client/src/pages/settings/preferences-registry.vue b/packages/client/src/pages/settings/preferences-registry.vue index 916bb3049..c01e4ee83 100644 --- a/packages/client/src/pages/settings/preferences-registry.vue +++ b/packages/client/src/pages/settings/preferences-registry.vue @@ -187,7 +187,7 @@ function loadFile() { async function applyRegistry(id: string) { if (!registries) return; - const registry = structuredClone(registries[id]); + const registry = registries[id]; const { canceled: cancel1 } = await os.confirm({ type: 'warning', diff --git a/packages/client/src/pizzax.ts b/packages/client/src/pizzax.ts index 5de866ef6..338898005 100644 --- a/packages/client/src/pizzax.ts +++ b/packages/client/src/pizzax.ts @@ -1,4 +1,4 @@ -import { onUnmounted, Ref, ref, watch } from 'vue'; +import { onUnmounted, Ref, ref, toRaw, watch } from 'vue'; import { $i } from './account'; import { api } from './os'; import { get, set } from './scripts/idb-proxy'; @@ -153,7 +153,7 @@ export class Storage { public set(key: K, value: T[K]['default']): Promise { // IndexedDBやBroadcastChannelで扱うために単純なオブジェクトにする // (JSON.parse(JSON.stringify(value))の代わり) - const rawValue = structuredClone(value); + const rawValue = structuredClone(toRaw(value)); if (_DEV_) console.log('set', key, rawValue, value);