]> us-delaporte.pagekite.me Git - matrix-shop-bot.git/blobdiff - matrix_shop_bot/bot.py
Update to print list after buying something
[matrix-shop-bot.git] / matrix_shop_bot / bot.py
index 1bd27334d35c42ba8383b37e2fe765396332911e..387cf184af205789ef5e4a919701166600df73ed 100644 (file)
@@ -91,7 +91,10 @@ async def do_shop(match):
     if match.command('buy'):
         item_id = ' '.join(match.args()[1:])
         Data().purchase_item(item_id)
     if match.command('buy'):
         item_id = ' '.join(match.args()[1:])
         Data().purchase_item(item_id)
-        return ['Success']
+        results = []
+        for item in Data().get_last_shopping_list():
+            results.append(str(item))
+        return results
 
     if match.command('clear'):
         store_id = ' '.join(match.args()[1:])
 
     if match.command('clear'):
         store_id = ' '.join(match.args()[1:])