From 86dd9c6ff91cabe770128196c8e1c6d217a3720e Mon Sep 17 00:00:00 2001 From: socks Date: Mon, 8 Mar 2021 14:27:50 +0000 Subject: [PATCH] Minor bugfixes --- mongo.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mongo.py b/mongo.py index 5a72c3a..bb6d6b3 100644 --- a/mongo.py +++ b/mongo.py @@ -73,6 +73,7 @@ def delete_stock(user, stock): if stock in portfolio.stocks.keys(): del portfolio.stocks[stock] portfolio.save() + return get_stocks(user) # Watchlist Stuff @@ -96,7 +97,7 @@ def watch(user, stock, est_price="0"): # Stock ticker does not exist on yahoo finance return False stock = encodeKey(stock) - watchlist.stocks[stock] = Decimal128(est_price) + watchlist.stocks[stock] = Decimal128(Decimal(est_price)) watchlist.save() return True