-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Set invoice state to canceled instead of failed
We can't really know if the invoice failed or got canceled. I think canceled is the better state name though.
- Loading branch information
Showing
5 changed files
with
12 additions
and
3 deletions.
There are no files selected for viewing
5 changes: 5 additions & 0 deletions
5
coordinator/migrations/2024-05-31-144618_add-canceled-invoice-state/down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
-- Postgres does not allow removing enum type values. One can only re-create an enum type with fewer values and replace the references. | ||
-- However, there is no proper way to replace the values to be removed where they are used (i.e. referenced in `hodl_invoice` table) | ||
-- We opt to NOT remove enum values that were added at a later point. | ||
|
||
select 1; |
1 change: 1 addition & 0 deletions
1
coordinator/migrations/2024-05-31-144618_add-canceled-invoice-state/up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TYPE "InvoiceState_Type" ADD VALUE IF NOT EXISTS 'Canceled'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters