Skip to content

Commit

Permalink
chore: migration - add created-by-user-id column to events
Browse files Browse the repository at this point in the history
  • Loading branch information
daveleek committed Dec 12, 2023
1 parent 43c563a commit 205d844
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions src/migrations/20231212094044-event-created-by-user-id.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
'use strict';

exports.up = function (db, callback) {
db.runSql(
`
ALTER TABLE events ADD COLUMN IF NOT EXISTS created_by_user_id INTEGER;
`,
callback,
);
};

exports.down = function (db, callback) {
db.runSql(
`
ALTER TABLE events DROP COLUMN IF EXISTS created_by_user_id;
`,
callback,
);
};

0 comments on commit 205d844

Please sign in to comment.