From ec99a978a474a6145931cd6d2a8c4a1df47df341 Mon Sep 17 00:00:00 2001 From: suddjian Date: Fri, 20 Oct 2023 23:25:22 -0700 Subject: [PATCH] fix null --- src/cookieclickermanager.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/cookieclickermanager.js b/src/cookieclickermanager.js index f26a515..4b6f74f 100644 --- a/src/cookieclickermanager.js +++ b/src/cookieclickermanager.js @@ -179,6 +179,9 @@ function analyzeStockMarket(buyPercentile=0.1, sellPercentile=0.3) { } function getStockTradeStr(good, amount) { + if (amount == null) { + amount = good.stock; + } var $ = Beautify(good.val * amount); var cookies = Beautify(Game.cookiesPsRawHighest * good.val * amount); return `${Beautify(amount)} ${good.symbol} at $${Beautify(good.val, 2)} for $${$} (${cookies} 🍪)`;