diff options
Diffstat (limited to 'server/initializers/migrations/0035-video-licence.ts')
-rw-r--r-- | server/initializers/migrations/0035-video-licence.ts | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/server/initializers/migrations/0035-video-licence.ts b/server/initializers/migrations/0035-video-licence.ts deleted file mode 100644 index b4224d758..000000000 --- a/server/initializers/migrations/0035-video-licence.ts +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | import * as Sequelize from 'sequelize' | ||
2 | import { Migration } from '../../models/migrations' | ||
3 | |||
4 | function up (utils: { | ||
5 | transaction: Sequelize.Transaction | ||
6 | queryInterface: Sequelize.QueryInterface | ||
7 | sequelize: Sequelize.Sequelize | ||
8 | }): Promise<void> { | ||
9 | const q = utils.queryInterface | ||
10 | |||
11 | const data = { | ||
12 | type: Sequelize.INTEGER, | ||
13 | allowNull: false, | ||
14 | defaultValue: 0 | ||
15 | } as Migration.Integer | ||
16 | |||
17 | return q.addColumn('Videos', 'licence', data) | ||
18 | .then(() => { | ||
19 | data.defaultValue = null | ||
20 | return q.changeColumn('Videos', 'licence', data) | ||
21 | }) | ||
22 | } | ||
23 | |||
24 | function down (options) { | ||
25 | throw new Error('Not implemented.') | ||
26 | } | ||
27 | |||
28 | export { | ||
29 | up, | ||
30 | down | ||
31 | } | ||