Skip to content

Commit

Permalink
Merge pull request #71 from ainize-team/fix/yoojin/balance_rule
Browse files Browse the repository at this point in the history
Fix balance write rule
  • Loading branch information
yoojinko authored Nov 1, 2023
2 parents f53026b + 98a54e0 commit 2be1e12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export const defaultAppRules = (appName: string): { [type: string]: { ref: strin
ref: Path.app(appName).balanceOfUser("$userAddress"),
value: {
".rule": {
write: "(util.isAppAdmin(`" + `${appName}` + "`, auth.addr, getValue) === true) && util.isNumber(newData) && newData > 0",
write: "(util.isAppAdmin(`" + `${appName}` + "`, auth.addr, getValue) === true) && util.isNumber(newData) && newData >= 0",
},
},
},
Expand Down

0 comments on commit 2be1e12

Please sign in to comment.