mirror of
https://gitlab.com/soapbox-pub/ditto.git
synced 2025-12-06 11:29:46 +00:00
DittoPgStore: destructure conf
This commit is contained in:
parent
7e00b9f9a2
commit
70d8c2ed59
1 changed files with 2 additions and 1 deletions
|
|
@ -170,9 +170,10 @@ export class DittoPgStore extends NPostgres {
|
||||||
event: NostrEvent,
|
event: NostrEvent,
|
||||||
opts: { signal?: AbortSignal; timeout?: number } = {},
|
opts: { signal?: AbortSignal; timeout?: number } = {},
|
||||||
): Promise<undefined> {
|
): Promise<undefined> {
|
||||||
|
const { conf } = this.opts;
|
||||||
try {
|
try {
|
||||||
await super.transaction(async (relay, kysely) => {
|
await super.transaction(async (relay, kysely) => {
|
||||||
await updateStats({ conf: this.opts.conf, relay, kysely: kysely as unknown as Kysely<DittoTables>, event });
|
await updateStats({ conf, relay, kysely: kysely as unknown as Kysely<DittoTables>, event });
|
||||||
await relay.event(event, opts);
|
await relay.event(event, opts);
|
||||||
});
|
});
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue