aboutsummaryrefslogtreecommitdiff
path: root/actions/admin/plugins/activate.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/admin/plugins/activate.php')
-rw-r--r--actions/admin/plugins/activate.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/actions/admin/plugins/activate.php b/actions/admin/plugins/activate.php
index 0d930b27f..feb986b27 100644
--- a/actions/admin/plugins/activate.php
+++ b/actions/admin/plugins/activate.php
@@ -29,7 +29,7 @@ foreach ($plugin_guids as $guid) {
if ($plugin->activate()) {
$activated_guids[] = $guid;
} else {
- register_error(elgg_echo('admin:plugins:activate:no', array($plugin->manifest->getName())));
+ register_error(elgg_echo('admin:plugins:activate:no', array($plugin->getManifest()->getName())));
}
}
@@ -39,7 +39,12 @@ elgg_invalidate_simplecache();
elgg_filepath_cache_reset();
if (count($activated_guids) === 1) {
- forward("admin/plugins/advanced#elgg-plugin-" . $plugin_guids[0]);
+ $url = 'admin/plugins';
+ $query = (string)parse_url($_SERVER['HTTP_REFERER'], PHP_URL_QUERY);
+ if ($query) {
+ $url .= "?$query";
+ }
+ forward($url . '#elgg-plugin-' . $plugin_guids[0]);
} else {
forward(REFERER);
} \ No newline at end of file