aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorcash <cash.costello@gmail.com>2011-11-18 22:40:04 -0500
committercash <cash.costello@gmail.com>2011-11-18 22:40:04 -0500
commit75c00c55dd9cc2de4d97f829d9b47c99eb4ba287 (patch)
treecd1dfe261b70cb0664a38ae3f89ab89b01e6a0f5 /engine
parentad161cd2bd5122c6a2adf65c5b8683d42f28b005 (diff)
downloadelgg-75c00c55dd9cc2de4d97f829d9b47c99eb4ba287.tar.gz
elgg-75c00c55dd9cc2de4d97f829d9b47c99eb4ba287.tar.bz2
Fixes #3792 admin can edit settings again
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/user_settings.php4
-rw-r--r--engine/lib/users.php5
2 files changed, 7 insertions, 2 deletions
diff --git a/engine/lib/user_settings.php b/engine/lib/user_settings.php
index 1e2d6db10..c71670357 100644
--- a/engine/lib/user_settings.php
+++ b/engine/lib/user_settings.php
@@ -265,8 +265,8 @@ function elgg_set_user_default_access() {
* @access private
*/
function usersettings_pagesetup() {
- if (elgg_get_context() == "settings" && elgg_get_logged_in_user_guid()) {
- $user = elgg_get_logged_in_user_entity();
+ if (elgg_get_context() == "settings") {
+ $user = elgg_get_page_owner_entity();
$params = array(
'name' => '1_account',
diff --git a/engine/lib/users.php b/engine/lib/users.php
index 29fa4db2f..3a86c1faa 100644
--- a/engine/lib/users.php
+++ b/engine/lib/users.php
@@ -1283,6 +1283,11 @@ function elgg_user_hover_menu($hook, $type, $return, $params) {
$item = new ElggMenuItem('profile:edit', elgg_echo('profile:edit'), $url);
$item->setSection('admin');
$return[] = $item;
+
+ $url = "settings/user/$user->username";
+ $item = new ElggMenuItem('settings:edit', elgg_echo('settings:edit'), $url);
+ $item->setSection('admin');
+ $return[] = $item;
}
return $return;