Beautify code

Beautify code in main.js