Skip to content

Commit b79c3f4

Browse files
committed
lint: lib/utils.ts
- add options.dialect in MySequelize type
1 parent 07205c6 commit b79c3f4

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

lib/models/baseModel.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,12 @@ import {Moment} from "moment";
22
import {Sequelize, Model, ModelCtor} from "sequelize";
33

44
export type MySequelize = Sequelize & {
5-
processData?: any
6-
stripNullByte?: any
5+
//data, _default, process
6+
processData?: (data: string | [], _default: string | [], process?: (string) => string) => void
7+
stripNullByte?: (string) => string
8+
options?: {
9+
dialect?: string
10+
} & Record<string, string>
711
}
812

913
export type BaseModel = {

lib/utils.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@ import * as path from "path";
44

55
import mime from "mime-types";
66
import bodyParser from "body-parser";
7+
import {MySequelize} from "./models/baseModel";
78

8-
export function isSQLite(sequelize): boolean {
9+
export function isSQLite(sequelize: MySequelize): boolean {
910
return sequelize.options.dialect === 'sqlite'
1011
}
1112

0 commit comments

Comments
 (0)