fixed another bug in main.py