function _update_no_data in Drupal 9
Same name and namespace in other branches
- 8 core/modules/update/update.module \_update_no_data()
- 6 modules/update/update.module \_update_no_data()
- 7 modules/update/update.module \_update_no_data()
- 10 core/modules/update/update.module \_update_no_data()
Returns a warning message when there is no data about available updates.
2 calls to _update_no_data()
- template_preprocess_update_report in core/
modules/ update/ update.report.inc - Prepares variables for project status report templates.
- update_requirements in core/
modules/ update/ update.install - Implements hook_requirements().
File
- core/
modules/ update/ update.module, line 249 - Handles updates of Drupal core and contributed projects.
Code
function _update_no_data() {
$destination = \Drupal::destination()
->getAsArray();
return t('No update information available. <a href=":run_cron">Run cron</a> or <a href=":check_manually">check manually</a>.', [
':run_cron' => Url::fromRoute('system.run_cron', [], [
'query' => $destination,
])
->toString(),
':check_manually' => Url::fromRoute('update.manual_status', [], [
'query' => $destination,
])
->toString(),
]);
}