original_string: protected static function is_course_modified($courseid, $since) {
          $logmang = get_log_manager();
          $readers = $logmang->get_readers('core\log\sql_reader');
          $params = array('courseid' => $courseid, 'since' => $since);
  
          foreach ($readers as $readerpluginname => $reader) {
              $where = "courseid = :courseid and timecreated > :since and crud <> 'r'";
  
              // Prevent logs of prevous backups causing a false positive.
              if ($readerpluginname != 'logstore_legacy') {
                  $where .= " and target <> 'course_backup'";
              }
  
              if ($reader->get_events_select_count($where, $params)) {
                  return true;
              }
          }
          return false;
      }
code: protected static function is_course_modified($courseid, $since) {
          $logmang = get_log_manager();
          $readers = $logmang->get_readers('core\log\sql_reader');
          $params = array('courseid' => $courseid, 'since' => $since);
  
          foreach ($readers as $readerpluginname => $reader) {
              $where = "courseid = :courseid and timecreated > :since and crud <> 'r'";
  
              // Prevent logs of prevous backups causing a false positive.
              if ($readerpluginname != 'logstore_legacy') {
                  $where .= " and target <> 'course_backup'";
              }
  
              if ($reader->get_events_select_count($where, $params)) {
                  return true;
              }
          }
          return false;
      }
code_tokens: protected static function is_course_modified ( $ courseid , $ since ) { $ logmang = get_log_manager ( ) ; $ readers = $ logmang -> get_readers ( 'core\log\sql_reader' ) ; $ params = array ( 'courseid' => $ courseid , 'since' => $ since ) ; foreach ( $ readers as $ readerpluginname => $ reader ) { $ where = "courseid = :courseid and timecreated > :since and crud <> 'r'" ; // Prevent logs of prevous backups causing a false positive. if ( $ readerpluginname != 'logstore_legacy' ) { $ where .= " and target <> 'course_backup'" ; } if ( $ reader -> get_events_select_count ( $ where , $ params ) ) { return true ; } } return false ; }
docstring: Check logs to find out if a course was modified since the given time.
  
  @param int $courseid course id to check
  @param int $since timestamp, from which to check
  
  @return bool true if the course was modified, false otherwise. This also returns false if no readers are enabled. This is
  intentional, since we cannot reliably determine if any modification was made or not.
docstring_tokens: Check logs to find out if a course was modified since the given time .