1
0
mirror of https://github.com/misskey-dev/misskey synced 2024-12-01 08:18:51 +09:00
This commit is contained in:
tamaina 2021-12-30 03:41:49 +09:00
parent 97696b18a6
commit e60517f53b

View File

@ -30,7 +30,7 @@ export class Storage<T extends StateDef> {
public readonly state = {} as State<T>;
public readonly reactiveState = {} as ReactiveState<T>;
// indexedDB保存を重複させないために簡易的にキューイング
// 簡易的にキューイングして占有ロックとする
private nextIdbJob: Promise<any> = Promise.resolve();
private addIdbSetJob<T>(job: () => Promise<T>) {
const promise = this.nextIdbJob.then(job, e => {