diff --git a/src/helpers/dice.js b/src/helpers/dice.js index d30cab8..4a8c6d1 100644 --- a/src/helpers/dice.js +++ b/src/helpers/dice.js @@ -18,7 +18,11 @@ export function getDiceInstanceRoll(instance) { highestLocator = locator; } } - return parseInt(highestLocator.name.slice(12)); + if (highestLocator) { + return parseInt(highestLocator.name.slice(12)); + } else { + return 0; + } } /**