Skip to content

Commit

Permalink
fix unnoticed error in contract
Browse files Browse the repository at this point in the history
  • Loading branch information
tenuki committed Nov 15, 2023
1 parent 4fdce49 commit a1da85c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion workspace-contracts/incrementer/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ mod incrementer {

#[ink(message)]
pub fn inc(&mut self, by: i32) {
self.value += by;
self.value = self.value.saturating_add(by);
}

#[ink(message)]
Expand Down

0 comments on commit a1da85c

Please sign in to comment.