original_string: public function notify_grade_modified($grade, $mailedoverride = false) {
          global $DB;
  
          $flags = $this->get_user_flags($grade->userid, true);
          if ($flags->mailed != 1 || $mailedoverride) {
              $flags->mailed = 0;
          }
  
          return $this->update_user_flags($flags);
      }
code: public function notify_grade_modified($grade, $mailedoverride = false) {
          global $DB;
  
          $flags = $this->get_user_flags($grade->userid, true);
          if ($flags->mailed != 1 || $mailedoverride) {
              $flags->mailed = 0;
          }
  
          return $this->update_user_flags($flags);
      }
code_tokens: public function notify_grade_modified ( $ grade , $ mailedoverride = false ) { global $ DB ; $ flags = $ this -> get_user_flags ( $ grade -> userid , true ) ; if ( $ flags -> mailed != 1 || $ mailedoverride ) { $ flags -> mailed = 0 ; } return $ this -> update_user_flags ( $ flags ) ; }
docstring: Mark in the database that this grade record should have an update notification sent by cron.
  
  @param stdClass $grade a grade record keyed on id
  @param bool $mailedoverride when true, flag notification to be sent again.
  @return bool true for success
docstring_tokens: Mark in the database that this grade record should have an update notification sent by cron .