? .completion.db
? .git
? .patch
? block.patch
? drushrc.php
? links.patch
? profile_render_array.patch
? tmp.patch
? tmp.patch.patch
? tmp.sql
? tracker.patch
? includes/.patch
? modules/node/node.diff.inc
? modules/node/node.pages-diff.inc
? modules/simpletest/tests/hook_url_rewrite.info
? modules/simpletest/tests/hook_url_rewrite.module
? modules/simpletest/tests/path.test
Index: modules/user/user.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/user/user.module,v
retrieving revision 1.976
diff -u -F^f -p -r1.976 user.module
--- modules/user/user.module	20 Apr 2009 02:23:17 -0000	1.976
+++ modules/user/user.module	20 Apr 2009 03:46:05 -0000
@@ -40,7 +40,7 @@ function user_theme() {
       'template' => 'user-picture',
     ),
     'user_profile' => array(
-      'arguments' => array('account' => NULL),
+      'arguments' => array('elements' => NULL),
       'template' => 'user-profile',
       'file' => 'user.pages.inc',
     ),
Index: modules/user/user.pages.inc
===================================================================
RCS file: /cvs/drupal/drupal/modules/user/user.pages.inc,v
retrieving revision 1.33
diff -u -F^f -p -r1.33 user.pages.inc
--- modules/user/user.pages.inc	13 Apr 2009 12:14:57 -0000	1.33
+++ modules/user/user.pages.inc	20 Apr 2009 03:46:05 -0000
@@ -148,15 +148,22 @@ function user_logout() {
 
 /**
  * Menu callback; Displays a user or user profile page.
+ * 
+ * To theme user profiles, copy modules/user/user-profile.tpl.php
+ * to your theme directory, and edit it as instructed in that file's comments.
  */
 function user_view($account) {
   drupal_set_title($account->name);
   // Retrieve all profile fields and attach to $account->content.
   user_build_content($account);
+  
+  $build = $account->content;
+  $build += array(
+    '#theme' => 'user_profile',
+    '#account' => $account,
+  );
 
-  // To theme user profiles, copy modules/user/user_profile.tpl.php
-  // to your theme directory, and edit it as instructed in that file's comments.
-  return theme('user_profile', $account);
+  return drupal_get_page($build);
 }
 
 /**
@@ -168,12 +175,14 @@ function user_view($account) {
  * @see user-picture.tpl.php
  */
 function template_preprocess_user_profile(&$variables) {
+  $account = $variables['elements']['#account'];
+  
   $variables['profile'] = array();
   // Sort sections by weight
-  uasort($variables['account']->content, 'element_sort');
+  uasort($account->content, 'element_sort');
   // Provide keyed variables so themers can print each section independently.
-  foreach (element_children($variables['account']->content) as $key) {
-    $variables['profile'][$key] = drupal_render($variables['account']->content[$key]);
+  foreach (element_children($account->content) as $key) {
+    $variables['profile'][$key] = drupal_render($account->content[$key]);
   }
   // Collect all profiles to make it easier to print all items at once.
   $variables['user_profile'] = implode($variables['profile']);
