Remove unused arguments in main function
Adapt to changes