You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
### MIGRATION 1494965078152_foo (UP) ###
BEGIN;
DROP TABLE "foo";
INSERT INTO "public"."pgmigrations" (name, run_on) VALUES ('1494965078152_foo', NOW());
COMMIT;
Note that is says it is running the UP migration, runs the command from the correct down migration, and then INSERT's instead of DELETE's from the pgmigrations table.
The problem seems to stem from the switch at line 59 of migrations.js. When the down migration is inferred this.up == this.down (see line 103 of migrations.js) so it always run the up action.
The text was updated successfully, but these errors were encountered:
Create a migration with no down method:
Run
pg-migrate up
and it shows:Then run
pg-migrate down
and it shows:Note that is says it is running the UP migration, runs the command from the correct down migration, and then INSERT's instead of DELETE's from the pgmigrations table.
The problem seems to stem from the switch at line 59 of migrations.js. When the down migration is inferred
this.up == this.down
(see line 103 of migrations.js) so it always run the up action.The text was updated successfully, but these errors were encountered: