Skip to content

Commit

Permalink
Fix migrations
Browse files Browse the repository at this point in the history
Signed-off-by: deniallugo <[email protected]>
  • Loading branch information
Deniallugo committed Aug 24, 2021
1 parent a7d2c97 commit a40d1cc
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
CREATE TYPE token_kind AS ENUM ('ERC20', 'NFT', 'None');
ALTER TABLE tokens ADD COLUMN kind token_kind NOT NULL DEFAULT 'ERC20';
UPDATE tokens SET kind = 'NFT' WHERE is_nft = true;
ALTER TABLE tokens DROP COLUMN is_nft;
2 changes: 1 addition & 1 deletion core/lib/storage/src/chain/state/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -789,7 +789,7 @@ impl<'a, 'c> StateSchema<'a, 'c> {
pub async fn mint_nft_updates_set_nonces(&mut self) -> QueryResult<()> {
let records = sqlx::query!(
r#"
SELECT tx FROM executed_transactions WHERE tx->'type' = '"MintNFT"'
SELECT tx FROM executed_transactions WHERE tx->'type' = '"MintNFT"' AND success = true
ORDER BY nonce
"#
)
Expand Down

0 comments on commit a40d1cc

Please sign in to comment.