mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-12-02 05:46:58 +01:00
test
This commit is contained in:
parent
8804f896b0
commit
cb6d38713f
1 changed files with 5 additions and 2 deletions
|
@ -2,6 +2,7 @@ import { onUnmounted, Ref, ref, watch } from 'vue';
|
||||||
import { $i } from './account';
|
import { $i } from './account';
|
||||||
import { api } from './os';
|
import { api } from './os';
|
||||||
import { get, set } from './scripts/idb-proxy';
|
import { get, set } from './scripts/idb-proxy';
|
||||||
|
import { defaultStore } from './store';
|
||||||
import { stream } from './stream';
|
import { stream } from './stream';
|
||||||
|
|
||||||
type StateDef = Record<string, {
|
type StateDef = Record<string, {
|
||||||
|
@ -95,11 +96,13 @@ export class Storage<T extends StateDef> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private async load(): Promise<void> {
|
private load(): Promise<void> {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
if ($i) {
|
if ($i) {
|
||||||
// api関数と循環参照なので一応setTimeoutしておく
|
// api関数と循環参照なので一応setTimeoutしておく
|
||||||
setTimeout(() => {
|
setTimeout(async () => {
|
||||||
|
await defaultStore.ready;
|
||||||
|
|
||||||
api('i/registry/get-all', { scope: ['client', this.key] })
|
api('i/registry/get-all', { scope: ['client', this.key] })
|
||||||
.then(kvs => {
|
.then(kvs => {
|
||||||
const cache = {};
|
const cache = {};
|
||||||
|
|
Loading…
Reference in a new issue