|
|
@ -213,10 +213,9 @@ class Console(QtGui.QPlainTextEdit): |
|
|
|
try: |
|
|
|
# eval is generally considered bad practice. use it wisely! |
|
|
|
result = eval(command, self.namespace, self.namespace) |
|
|
|
result = util.json_encode(result) |
|
|
|
if result != None: |
|
|
|
if self.is_json: |
|
|
|
util.print_msg(result) |
|
|
|
util.print_msg(util.json_encode(result)) |
|
|
|
else: |
|
|
|
self.appendPlainText(repr(result)) |
|
|
|
except SyntaxError: |
|
|
|