Cleaning up deprecated code from grade.php and grade_model.php