Revised grader.js to accept url and file input