Remove AdminStore from storages

This commit is contained in:
Alex Gleason 2025-02-21 15:08:58 -06:00
parent e5657d67c0
commit 72851bc536
No known key found for this signature in database
GPG key ID: 7211D1F99744FBB7

View file

@ -5,7 +5,6 @@ import { logi } from '@soapbox/logi';
import { Conf } from '@/config.ts';
import { wsUrlSchema } from '@/schema.ts';
import { AdminStore } from '@/storages/AdminStore.ts';
import { DittoPgStore } from '@/storages/DittoPgStore.ts';
import { getRelays } from '@/utils/outbox.ts';
import { seedZapSplits } from '@/utils/zap-split.ts';
@ -13,7 +12,6 @@ import { seedZapSplits } from '@/utils/zap-split.ts';
export class Storages {
private static _db: Promise<DittoPgStore> | undefined;
private static _database: Promise<DittoDB> | undefined;
private static _admin: Promise<AdminStore> | undefined;
private static _client: Promise<NPool<NRelay1>> | undefined;
public static async database(): Promise<DittoDB> {
@ -53,14 +51,6 @@ export class Storages {
return this._db;
}
/** Admin user storage. */
public static async admin(): Promise<AdminStore> {
if (!this._admin) {
this._admin = Promise.resolve(new AdminStore(await this.db()));
}
return this._admin;
}
/** Relay pool storage. */
public static async client(): Promise<NPool<NRelay1>> {
if (!this._client) {