From d78f7b2ede6a06627412d97ed301ed4ffe9d5ad8 Mon Sep 17 00:00:00 2001 From: robertem <3456661+RandomGamer342@users.noreply.github.com> Date: Mon, 20 Feb 2017 12:37:56 +0000 Subject: [PATCH] Fixed bug preventing superfast mode from being set. Fixed bug when printing warning star next to user in purchase list. --- text_interface/buymenu.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/text_interface/buymenu.py b/text_interface/buymenu.py index 8e197f2..6e53f95 100644 --- a/text_interface/buymenu.py +++ b/text_interface/buymenu.py @@ -95,7 +95,7 @@ When finished, write an empty line to confirm the purchase.\n''' def is_product(candidate): return isinstance(candidate, Product) - if len(initial_contents) > 0 and all(map(is_product, initial_contents)): + if len(initial_contents) > 0 and all(map(is_product, initial_contents[0])): self.superfast_mode = True print '***********************************************' print '****** Buy menu is in SUPERFASTmode[tm]! ******' @@ -175,7 +175,7 @@ When finished, write an empty line to confirm the purchase.\n''' string += '(empty)' else: string += ', '.join( - map(lambda t: t.user.name + ("*" if t.user.credit < conf.user_recent_transaction_limit else ""), + map(lambda t: t.user.name + ("*" if not self.credit_check(t.user) else ""), transactions)) string += '\n products: ' if len(entries) == 0: