fixed silly error in grading function that didnt correctly query assignment_type