summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-02-23 04:54:24 +0000
committerBharat Mediratta <bharat@menalto.com>2009-02-23 04:54:24 +0000
commit490a182f85dded2804371459f4e3da89ae9a1066 (patch)
tree8953a38fc44c389c7ceaefc0f8173267efbea9a1
parent2ab18bbd45d9ec09223e785a66d6488013c99876 (diff)
Move admin menu under settings
Don't try to show the local_import link if there's no options menu.
-rw-r--r--modules/local_import/helpers/local_import_menu.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/local_import/helpers/local_import_menu.php b/modules/local_import/helpers/local_import_menu.php
index cb3029a2..c32b15ad 100644
--- a/modules/local_import/helpers/local_import_menu.php
+++ b/modules/local_import/helpers/local_import_menu.php
@@ -19,7 +19,7 @@
*/
class local_import_menu_Core {
static function admin($menu, $theme) {
- $menu->get("content_menu")
+ $menu->get("settings_menu")
->append(Menu::factory("link")
->id("local_import")
->label(t("Local Import"))
@@ -31,8 +31,9 @@ class local_import_menu_Core {
$paths = unserialize(module::get_var("local_import", "authorized_paths"));
- if ($item && access::can("local_import", $item) && $item->is_album() &&!empty($paths)) {
- $menu->get("options_menu")
+ if ($item && access::can("edit", $item) && access::can("local_import", $item) &&
+ $item->is_album() && !empty($paths)) {
+ $options_menu = $menu->get("options_menu")
->append(Menu::factory("dialog")
->id("local_import")
->label(t("Import from server"))