diff --git a/core/modules/system/system.install b/core/modules/system/system.install
index 4c7162c..f01a387 100644
--- a/core/modules/system/system.install
+++ b/core/modules/system/system.install
@@ -353,21 +353,30 @@ function system_requirements($phase) {
$summary = t('Last run !time ago', array('!time' => \Drupal::service('date.formatter')->formatInterval(REQUEST_TIME - $cron_last)));
$description = '';
if ($severity != REQUIREMENT_INFO) {
- $description = t('Cron has not run recently.') . ' ' . $help;
+ $description = t('Cron has not run recently.') . ' ' . $help . ' ';
}
- $description .= ' ' . t('You can run cron manually.', array('@cron' => \Drupal::url('system.run_cron')));
- $description .= '
' . t('To run cron from outside the site, go to !cron', array('!cron' => \Drupal::url('system.cron', array('key' => \Drupal::state()->get('system.cron_key'), array('absolute' => TRUE)))));
+ $description .= t('You can run cron manually.', array('@cron' => \Drupal::url('system.run_cron'))) . ' ';
+
+ // Get cron key.
+ $cron_key = \Drupal::state()->get('system.cron_key');
+ // Get cron run outside url.
+ $cron_outside_url = \Drupal::url('system.cron', array('key' => $cron_key), array('absolute' => TRUE));
+ $description .= '
' . t('To run cron from outside the site, go to !cron', array('!cron' => $cron_outside_url));
+
+ // The $description string is concatenated from t() calls, so safe.
+ // We can implement raw filter in the inline_template call.
+ $description = array(
+ '#type' => 'inline_template',
+ '#template' => '{{ description|raw }}',
+ '#context' => array('description' => $description),
+ );
$requirements['cron'] = array(
'title' => t('Cron maintenance tasks'),
'severity' => $severity,
'value' => $summary,
- // @todo This string is concatenated from t() calls, safe drupal_render()
- // output, whitespace, and
tags, so is safe. However, as a best
- // practice, we should not use SafeMarkup::set() around a variable. Fix
- // in: https://www.drupal.org/node/2296929
- 'description' => SafeMarkup::set($description),
+ 'description' => \Drupal::service('renderer')->render($description),
);
}
if ($phase != 'install') {