Uploaded image for project: 'Plugins'
  1. Plugins
  2. CONTRIB-8800

Incorrectly evaluating $lastcron

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 3.9.11, 3.10.8, 3.11.4
    • None
    • 2020110300 and earlier
    • MOODLE_310_STABLE, MOODLE_311_STABLE, MOODLE_39_STABLE

      Refer to the code in https://github.com/jleyva/moodle-block_configurablereports/blob/f63cf94c9f14d5ce36d872c2cd67179a571db530/block_configurable_reports.php#L183:

      $lastcron = $DB->get_field('block', 'lastcron', array('name' => 'configurable_reports'));
      *if (!$lastcron and ($lastcron + $this->cron < time()) )*

      { return false; }

      Should that if() statement use *!$lastcron* or *$lastcron*?

      See the comments in https://moodle.org/mod/forum/discuss.php?d=429769 and https://moodle.org/mod/forum/discuss.php?d=409387

      Issue discovered on:
      $plugin->version = 2020110300;
      $plugin->release = '3.9.0';

            jleyva Juan Leyva
            libertymoodle Luis de Vasconcelos
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.