mirror of
https://github.com/mattermost/mattermost-mobile.git
synced 2026-11-04 09:58:57 +00:00
11 lines
386 B
TypeScript
11 lines
386 B
TypeScript
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
|
|
import {getFullErrorMessage} from '@utils/errors';
|
|
|
|
const DATABASE_CORRUPTION_MESSAGE = 'database disk image is malformed';
|
|
|
|
export function isDatabaseCorruptionError(error: unknown): boolean {
|
|
return getFullErrorMessage(error).includes(DATABASE_CORRUPTION_MESSAGE);
|
|
}
|