Skip to content

Commit

Permalink
Use constant for placeholder column name
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-farries committed Dec 16, 2024
1 parent 19edffa commit 3de40ab
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions pkg/sql2pgroll/alter_table.go
Original file line number Diff line number Diff line change
Expand Up @@ -370,10 +370,10 @@ func convertAlterTableDropConstraint(stmt *pgq.AlterTableStmt, cmd *pgq.AlterTab

return &migrations.OpDropMultiColumnConstraint{
Up: migrations.MultiColumnUpSQL{
"placeholder": PlaceHolderSQL,
PlaceHolderColumnName: PlaceHolderSQL,
},
Down: migrations.MultiColumnDownSQL{
"placeholder": PlaceHolderSQL,
PlaceHolderColumnName: PlaceHolderSQL,
},
Table: tableName,
Name: cmd.GetName(),
Expand Down
4 changes: 2 additions & 2 deletions pkg/sql2pgroll/expect/drop_constraint.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ import (
func OpDropConstraintWithTable(table string) *migrations.OpDropMultiColumnConstraint {
return &migrations.OpDropMultiColumnConstraint{
Up: migrations.MultiColumnUpSQL{
"placeholder": sql2pgroll.PlaceHolderSQL,
sql2pgroll.PlaceHolderColumnName: sql2pgroll.PlaceHolderSQL,
},
Down: migrations.MultiColumnDownSQL{
"placeholder": sql2pgroll.PlaceHolderSQL,
sql2pgroll.PlaceHolderColumnName: sql2pgroll.PlaceHolderSQL,
},
Table: table,
Name: "constraint_foo",
Expand Down

0 comments on commit 3de40ab

Please sign in to comment.