-
Notifications
You must be signed in to change notification settings - Fork 12
PRO-3097-MTP_V07 #201
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PRO-3097-MTP_V07 #201
Changes from all commits
9f0ba53
599c840
7fcd381
5fffe19
49e693f
4ff85a1
c5d185d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| require('dotenv').config(); | ||
|
|
||
| async function up({ context: queryInterface }) { | ||
| await queryInterface.sequelize.query(`ALTER TABLE IF EXISTS "${process.env.DATABASE_SCHEMA_NAME}".api_keys ADD COLUMN "MULTI_TOKEN_PAYMASTERS_V2" text default null`); | ||
| } | ||
|
|
||
| async function down({ context: queryInterface }) { | ||
| await queryInterface.sequelize.query(`ALTER TABLE IF EXISTS "${process.env.DATABASE_SCHEMA_NAME}".api_keys DROP COLUMN MULTI_TOKEN_PAYMASTERS_V2;`); | ||
| } | ||
|
|
||
| module.exports = { up, down } |
| Original file line number | Diff line number | Diff line change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,11 @@ | ||||||||||||||
| require('dotenv').config(); | ||||||||||||||
|
|
||||||||||||||
| async function up({ context: queryInterface }) { | ||||||||||||||
| await queryInterface.sequelize.query(`ALTER TABLE IF EXISTS "${process.env.DATABASE_SCHEMA_NAME}".multi_token_paymaster ADD COLUMN "EP_VERSION" text default 'EPV_06'`); | ||||||||||||||
| } | ||||||||||||||
vignesha22 marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||||||||||
|
|
||||||||||||||
| async function down({ context: queryInterface }) { | ||||||||||||||
| await queryInterface.sequelize.query(`ALTER TABLE "${process.env.DATABASE_SCHEMA_NAME}".multi_token_paymaster DROP COLUMN EP_VERSION;`); | ||||||||||||||
| } | ||||||||||||||
|
Comment on lines
+7
to
+9
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Add IF EXISTS clause to the down migration. The down migration should include an - await queryInterface.sequelize.query(`ALTER TABLE "${process.env.DATABASE_SCHEMA_NAME}".multi_token_paymaster DROP COLUMN EP_VERSION;`);
+ await queryInterface.sequelize.query(`ALTER TABLE IF EXISTS "${process.env.DATABASE_SCHEMA_NAME}".multi_token_paymaster DROP COLUMN EP_VERSION;`);📝 Committable suggestion
Suggested change
|
||||||||||||||
|
|
||||||||||||||
| module.exports = { up, down } | ||||||||||||||
Uh oh!
There was an error while loading. Please reload this page.