Treat "file is not a database" as database corruption

Co-authored-by: Fedor Indutny <79877362+indutny-signal@users.noreply.github.com>
This commit is contained in:
automated-signal 2021-11-17 13:39:37 -08:00 committed by GitHub
parent 05a79c7054
commit 4e5ccb5ed4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -5,6 +5,7 @@ export function isCorruptionError(error?: Error): boolean {
return (
error?.message?.includes('SQLITE_CORRUPT') ||
error?.message?.includes('database disk image is malformed') ||
error?.message?.includes('file is not a database') ||
false
);
}