chore: merge blocksuite source code (#9213)
This commit is contained in:
20
blocksuite/framework/store/src/schema/error.ts
Normal file
20
blocksuite/framework/store/src/schema/error.ts
Normal file
@@ -0,0 +1,20 @@
|
||||
import { BlockSuiteError, ErrorCode } from '@blocksuite/global/exceptions';
|
||||
|
||||
export class MigrationError extends BlockSuiteError {
|
||||
constructor(description: string) {
|
||||
super(
|
||||
ErrorCode.MigrationError,
|
||||
`Migration failed. Please report to https://github.com/toeverything/blocksuite/issues
|
||||
${description}`
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export class SchemaValidateError extends BlockSuiteError {
|
||||
constructor(flavour: string, message: string) {
|
||||
super(
|
||||
ErrorCode.SchemaValidateError,
|
||||
`Invalid schema for ${flavour}: ${message}`
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user