adding checks and grade.js