From e18ac58ef23a75422b45d71ba83dd8466fb6433d Mon Sep 17 00:00:00 2001 From: od-hunter Date: Mon, 30 Sep 2024 18:37:12 +0100 Subject: [PATCH] refac: update withdraw function to clear mapping --- apps/blockchain/starknet/src/bridge.cairo | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/blockchain/starknet/src/bridge.cairo b/apps/blockchain/starknet/src/bridge.cairo index 0b734875..75daf640 100644 --- a/apps/blockchain/starknet/src/bridge.cairo +++ b/apps/blockchain/starknet/src/bridge.cairo @@ -160,6 +160,9 @@ mod bridge { if is_escrowed { IERC721Dispatcher { contract_address: collection_l2 } .transfer_from(from, to, token_id); + + let null_value = starknet::contract_address_const::<0>(); + self.escrow.write((collection_l2, token_id), null_value); } else { if (req.uris.len() != 0) { let token_uri = req.uris[i];