return transaction context

This commit is contained in:
Florian Dold 2021-06-09 16:20:50 +02:00
parent 029b07be4b
commit 2d4a53f522
No known key found for this signature in database
GPG Key ID: D2E4F00F29D02A4B
2 changed files with 1 additions and 20 deletions

View File

@ -1510,10 +1510,6 @@ export interface RecoupGroupRecord {
lastError: TalerErrorDetails | undefined;
}
export enum ImportPayloadType {
CoreSchema = "core-schema",
}
export enum BackupProviderStatus {
PaymentRequired = "payment-required",
Ready = "ready",

View File

@ -77,22 +77,6 @@ function requestToPromise(req: IDBRequest): Promise<any> {
});
}
function transactionToPromise(tx: IDBTransaction): Promise<void> {
const stack = Error("Failed transaction was started here.");
return new Promise((resolve, reject) => {
tx.onabort = () => {
reject(TransactionAbort);
};
tx.oncomplete = () => {
resolve();
};
tx.onerror = () => {
console.error("Transaction failed:", stack);
reject(tx.error);
};
});
}
type CursorResult<T> = CursorEmptyResult<T> | CursorValueResult<T>;
interface CursorEmptyResult<T> {
@ -548,6 +532,7 @@ function makeWriteContext(
},
};
}
return ctx;
}
/**