Skip to content

Commit

Permalink
fix migration for postgres
Browse files Browse the repository at this point in the history
  • Loading branch information
riccardobl committed Sep 2, 2024
1 parent 3344440 commit 29b1b17
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions migrations.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ async def m001_initial(db):
pubkey TEXT NOT NULL,
amount_msats INTEGER NOT NULL,
created_at INTEGER NOT NULL,
FOREIGN KEY(pubkey) REFERENCES keys(pubkey) ON DELETE CASCADE
FOREIGN KEY(pubkey) REFERENCES {db.references_schema}keys(pubkey) ON DELETE CASCADE
);
"""
)
Expand All @@ -36,7 +36,7 @@ async def m001_initial(db):
pubkey TEXT NOT NULL,
payload TEXT NOT NULL,
created_at INTEGER NOT NULL,
FOREIGN KEY(pubkey) REFERENCES keys(pubkey) ON DELETE CASCADE
FOREIGN KEY(pubkey) REFERENCES {db.references_schema}keys(pubkey) ON DELETE CASCADE
);
"""
)
Expand All @@ -49,7 +49,7 @@ async def m001_initial(db):
budget_msats INTEGER NOT NULL,
refresh_window INTEGER NOT NULL,
created_at INTEGER NOT NULL,
FOREIGN KEY(pubkey) REFERENCES keys(pubkey) ON DELETE CASCADE
FOREIGN KEY(pubkey) REFERENCES {db.references_schema}keys(pubkey) ON DELETE CASCADE
);
"""
)
Expand Down

0 comments on commit 29b1b17

Please sign in to comment.