fix to main.js