mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-08-14 22:33:44 -05:00
Custom flow in pick/ban (#2923)
This commit is contained in:
@@ -7,6 +7,15 @@ export function errorIsSqliteForeignKeyConstraintFailure(
|
||||
);
|
||||
}
|
||||
|
||||
export function errorIsSqliteUniqueConstraintFailure(
|
||||
error: unknown,
|
||||
): error is Error {
|
||||
return (
|
||||
error instanceof Error &&
|
||||
error?.message?.includes("UNIQUE constraint failed")
|
||||
);
|
||||
}
|
||||
|
||||
export function parseDBJsonArray(value: any) {
|
||||
const parsed = JSON.parse(value);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user