Fix error in main