Open cameron1729 opened 2 years ago
The tool_crawler_crawl function uses the plugin setting crawlstart (from the mdl_config_plugins table) to find a record in mdl_tool_crawler_history. It is possible that there can be no such record with this value in mdl_tool_crawler history.
crawlstart
mdl_config_plugins
mdl_tool_crawler_history
mdl_tool_crawler history
The record from the history table is attempted to be loaded here: https://github.com/catalyst/moodle-tool_crawler/blob/MOODLE_310_STABLE/lib.php#L75
If it isn't found, no error is raised. Then later an attempt to write to the DB is made here: https://github.com/catalyst/moodle-tool_crawler/blob/MOODLE_310_STABLE/lib.php#L96 but it fails since we have no ID.
The tool_crawler_crawl function uses the plugin setting
crawlstart
(from themdl_config_plugins
table) to find a record inmdl_tool_crawler_history
. It is possible that there can be no such record with this value inmdl_tool_crawler history
.The record from the history table is attempted to be loaded here: https://github.com/catalyst/moodle-tool_crawler/blob/MOODLE_310_STABLE/lib.php#L75
If it isn't found, no error is raised. Then later an attempt to write to the DB is made here: https://github.com/catalyst/moodle-tool_crawler/blob/MOODLE_310_STABLE/lib.php#L96 but it fails since we have no ID.