fix: incorrect effective caller when in strict mode (#324)
This commit is contained in:
@@ -20,7 +20,7 @@ export async function handle(state, action) {
|
||||
throw new ContractError('Invalid token transfer');
|
||||
}
|
||||
|
||||
if (balances[caller] < qty) {
|
||||
if (!balances[caller] || balances[caller] < qty) {
|
||||
throw new ContractError(`Caller balance not high enough to send ${qty} token(s)!`);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user