Skip to content

Commit

Permalink
fix: change order or variable setting, following CEI pattern (#173)
Browse files Browse the repository at this point in the history
  • Loading branch information
uri-99 authored Feb 26, 2024
1 parent f51428f commit 452f634
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion contracts/cairo/src/escrow.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ mod Escrow {
self.orders_pending.write(order_id, true);
self.orders_senders.write(order_id, get_caller_address());
self.orders_timestamps.write(order_id, get_block_timestamp());
self.current_order_id.write(order_id + 1);

dispatcher.transferFrom(get_caller_address(), get_contract_address(), payment_amount);

Expand All @@ -178,7 +179,6 @@ mod Escrow {
}
);

self.current_order_id.write(order_id + 1);
order_id
}

Expand Down

0 comments on commit 452f634

Please sign in to comment.