Update main.js

Update main.js, can calculate now.