diff options
author | Rigel Kent <sendmemail@rigelk.eu> | 2018-07-25 22:01:25 +0200 |
---|---|---|
committer | Rigel Kent <sendmemail@rigelk.eu> | 2018-07-25 22:01:25 +0200 |
commit | c1e791bad0b079af67398f6407221e6dcbb573dd (patch) | |
tree | 82e5944b4458dd35aa482a38f6b650eb93bb89ad /server/models/migrations | |
parent | 5f7021c33d31c5255b995ae0ff86b5bbea4ea4b9 (diff) | |
download | PeerTube-c1e791bad0b079af67398f6407221e6dcbb573dd.tar.gz PeerTube-c1e791bad0b079af67398f6407221e6dcbb573dd.tar.zst PeerTube-c1e791bad0b079af67398f6407221e6dcbb573dd.zip |
expliciting type checks and predicates (server only)
Diffstat (limited to 'server/models/migrations')
-rw-r--r-- | server/models/migrations/index.ts | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/server/models/migrations/index.ts b/server/models/migrations/index.ts new file mode 100644 index 000000000..c2b31b05e --- /dev/null +++ b/server/models/migrations/index.ts | |||
@@ -0,0 +1,23 @@ | |||
1 | import * as Sequelize from 'sequelize' | ||
2 | |||
3 | declare namespace Migration { | ||
4 | interface Boolean extends Sequelize.DefineAttributeColumnOptions { | ||
5 | defaultValue: boolean | null | ||
6 | } | ||
7 | |||
8 | interface String extends Sequelize.DefineAttributeColumnOptions { | ||
9 | defaultValue: string | null | ||
10 | } | ||
11 | |||
12 | interface Integer extends Sequelize.DefineAttributeColumnOptions { | ||
13 | defaultValue: number | null | ||
14 | } | ||
15 | |||
16 | interface BigInteger extends Sequelize.DefineAttributeColumnOptions { | ||
17 | defaultValue: Sequelize.DataTypeBigInt | number | null | ||
18 | } | ||
19 | } | ||
20 | |||
21 | export { | ||
22 | Migration | ||
23 | } | ||