fix whitespace variable to "0"

This commit is contained in:
LenAnderson
2024-07-20 11:59:52 -04:00
parent 6e7e57518e
commit 4336253b2f
2 changed files with 3 additions and 3 deletions

View File

@ -97,7 +97,7 @@ export class SlashCommandScope {
return v ?? '';
} else {
const value = this.variables[key];
return (value === '' || isNaN(Number(value))) ? (value || '') : Number(value);
return (value?.trim?.() === '' || isNaN(Number(value))) ? (value || '') : Number(value);
}
}
if (this.parent) {