Fix for an Issue #140

This commit is contained in:
Miroslav Stampar
2012-08-07 10:57:29 +02:00
parent fec8a5cc9d
commit 31ceb0cb6c
2 changed files with 4 additions and 2 deletions

View File

@@ -701,7 +701,7 @@ def setColor(message, bold=False):
retVal = message
level = extractRegexResult(r"\[(?P<result>[A-Z ]+)\]", message) or kb.get("stickyLevel")
if message and hasattr(LOGGER_HANDLER, "level_map"): # colorizing handler
if message and getattr(LOGGER_HANDLER, "is_tty", False): # colorizing handler
if bold:
retVal = colored(message, color=None, on_color=None, attrs=("bold",))
elif level: