diff options
Diffstat (limited to 'src/lib/models/BaseModel.ts')
-rw-r--r-- | src/lib/models/BaseModel.ts | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/models/BaseModel.ts b/src/lib/models/BaseModel.ts index f1521dd..8ed5ed3 100644 --- a/src/lib/models/BaseModel.ts +++ b/src/lib/models/BaseModel.ts @@ -1,17 +1,19 @@ import { Model } from 'sequelize'; +const NEVER_USED = 'This should never be executed'; + export abstract class BaseModel<A, B> extends Model<A, B> { /** * The date when the row was created. */ public get createdAt(): Date { - throw new Error('This should never be executed'); + throw new Error(NEVER_USED); } /** * The date when the row was last updated. */ public get updatedAt(): Date { - throw new Error('This should never be executed'); + throw new Error(NEVER_USED); } } |