mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-12-23 21:43:09 +02:00
wip?
This commit is contained in:
parent
d77fa3bb08
commit
2012f4a198
1 changed files with 2 additions and 1 deletions
|
@ -74,8 +74,9 @@ export class Storage<T extends StateDef> {
|
||||||
|
|
||||||
// streamingのuser storage updateイベントを監視して更新
|
// streamingのuser storage updateイベントを監視して更新
|
||||||
this.connection.on('registryUpdated', ({ scope, key, value }) => {
|
this.connection.on('registryUpdated', ({ scope, key, value }) => {
|
||||||
this.state[key] = value;
|
this.state[key] = value as typeof this.state[key]['default'];
|
||||||
this.reactiveState[key].value = value;
|
this.reactiveState[key].value = value;
|
||||||
|
|
||||||
const cache = JSON.parse(localStorage.getItem(this.keyForLocalStorage + '::cache::' + $i.id) || '{}');
|
const cache = JSON.parse(localStorage.getItem(this.keyForLocalStorage + '::cache::' + $i.id) || '{}');
|
||||||
cache[key] = value;
|
cache[key] = value;
|
||||||
localStorage.setItem(this.keyForLocalStorage + '::cache::' + $i.id, JSON.stringify(cache));
|
localStorage.setItem(this.keyForLocalStorage + '::cache::' + $i.id, JSON.stringify(cache));
|
||||||
|
|
Loading…
Reference in a new issue