Fix console module when the console is not presented
@@ -7,11 +7,12 @@ import PytoClasses
import mainthread
__PyContentViewController__ = PytoClasses.PyContentViewController
-__console__ = __PyContentViewController__.shared.viewController.viewControllers[0]
+def __console__():
+ return __PyContentViewController__.shared.viewController.viewControllers[0]
def __clear__() -> None:
- __console__.textView.text = ""
- __console__.console = ""
+ __console__().textView.text = ""
+ __console__().console = ""
def clear():
"""
