summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Pott2013-07-20 20:35:36 +0100
committerAlex Pott2013-07-20 20:35:36 +0100
commit36d5732ff8a06e72fb4ec6abe519850ef0912711 (patch)
tree3c752e7912bf87a56d306c4a923b5d9c2de45bd5
parent91fbd4b5ca4781a9a8279754c1c952e79ffbce3c (diff)
Issue #2009688 by tsphethean, aaronott: Replace theme() with drupal_render() in update module.
-rw-r--r--core/update.php33
1 files changed, 28 insertions, 5 deletions
diff --git a/core/update.php b/core/update.php
index fba6b86..607a1b7 100644
--- a/core/update.php
+++ b/core/update.php
@@ -225,7 +225,11 @@ function update_results_page() {
$output .= "<p><strong>Reminder: don't forget to set the <code>\$settings['update_free_access']</code> value in your <code>settings.php</code> file back to <code>FALSE</code>.</strong></p>";
}
- $output .= theme('links', array('links' => update_helpful_links()));
+ $links = array(
+ '#theme' => 'links',
+ '#links' => update_helpful_links(),
+ );
+ $output .= drupal_render($links);
// Output a list of queries executed.
if (!empty($_SESSION['update_results'])) {
@@ -371,7 +375,13 @@ function update_task_list($active = NULL) {
'finished' => 'Review log',
);
- drupal_add_region_content('sidebar_first', theme('task_list', array('items' => $tasks, 'active' => $active)));
+ $task_list = array(
+ '#theme' => 'task_list',
+ '#items' => $tasks,
+ '#active' => $active,
+ );
+
+ drupal_add_region_content('sidebar_first', drupal_render($task_list));
}
/**
@@ -404,10 +414,18 @@ function update_check_requirements($skip_warnings = FALSE) {
if ($severity == REQUIREMENT_ERROR || ($severity == REQUIREMENT_WARNING && !$skip_warnings)) {
update_task_list('requirements');
drupal_set_title('Requirements problem');
- $status_report = theme('status_report', array('requirements' => $requirements));
+ $status = array(
+ '#theme' => 'status_report',
+ '#requirements' => $requirements,
+ );
+ $status_report = drupal_render($status);
$status_report .= 'Check the messages and <a href="' . check_url(drupal_requirements_url($severity)) . '">try again</a>.';
drupal_add_http_header('Content-Type', 'text/html; charset=utf-8');
- print theme('maintenance_page', array('content' => $status_report));
+ $maintenance_page = array(
+ '#theme' => 'maintenance_page',
+ '#content' => $status_report,
+ );
+ print drupal_render($maintenance_page);
exit();
}
}
@@ -546,6 +564,11 @@ if (isset($output) && $output) {
}
else {
drupal_add_http_header('Content-Type', 'text/html; charset=utf-8');
- print theme('maintenance_page', array('content' => $output, 'show_messages' => !$progress_page));
+ $maintenance_page = array(
+ '#theme' => 'maintenance_page',
+ '#content' => $output,
+ '#show_messages' => !$progress_page,
+ );
+ print drupal_render($maintenance_page);
}
}