From 3ea52e52fd8b357a00bce8dbfcbe4061331acb08 Mon Sep 17 00:00:00 2001 From: Patrick Kanzler Date: Fri, 27 Nov 2015 21:22:27 +0100 Subject: [PATCH] REFACTOR chained boolean expression in escpos --- escpos/escpos.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/escpos/escpos.py b/escpos/escpos.py index 045a4fd..37eed91 100644 --- a/escpos/escpos.py +++ b/escpos/escpos.py @@ -95,7 +95,7 @@ class Escpos: else: pix_line += im_pattern[x] break - elif im_color > (255 * 3 / pattern_len * pattern_len) and im_color <= (255 * 3): + elif (255 * 3 / pattern_len * pattern_len) < im_color <= (255 * 3): pix_line += im_pattern[-1] break pix_line += im_right