summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authortamaina <tamaina@hotmail.co.jp>2021-12-30 02:57:56 +0900
committertamaina <tamaina@hotmail.co.jp>2021-12-30 02:57:56 +0900
commit93e3aede354aac458db444e5a47060fc3b01cc3f (patch)
tree482872cbe8c0124d6653821d7e4a517968b53e57 /packages
parentfix pizzax (#8099) (diff)
downloadmisskey-93e3aede354aac458db444e5a47060fc3b01cc3f.tar.gz
misskey-93e3aede354aac458db444e5a47060fc3b01cc3f.tar.bz2
misskey-93e3aede354aac458db444e5a47060fc3b01cc3f.zip
スコープの判定を厳密に
Diffstat (limited to 'packages')
-rw-r--r--packages/client/src/pizzax.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/client/src/pizzax.ts b/packages/client/src/pizzax.ts
index fc01e92ee7..dbbbfc228a 100644
--- a/packages/client/src/pizzax.ts
+++ b/packages/client/src/pizzax.ts
@@ -74,7 +74,7 @@ export class Storage<T extends StateDef> {
}, 1);
// streamingのuser storage updateイベントを監視して更新
connection?.on('registryUpdated', ({ scope, key, value }: { scope: string[], key: keyof T, value: T[typeof key]['default'] }) => {
- if (scope[1] !== this.key || this.state[key] === value) return;
+ if (scope.length !== 2 || scope[0] !== 'client' || scope[1] !== this.key || this.state[key] === value) return;
this.state[key] = value;
this.reactiveState[key].value = value;