fixed bugs in grader.js