diff options
author | Bharat Mediratta <bharat@menalto.com> | 2009-11-17 15:36:02 -0800 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2009-11-17 15:36:02 -0800 |
commit | b8e94302bd673f89beb63530bbb7cdfe3ce56da9 (patch) | |
tree | 86ad449a0cc7aaf371609f2431adbf2ae048445f /modules/gallery/helpers/theme.php | |
parent | 1067e68292852f524fceda4c6cf7cd5f7110b234 (diff) |
Tweak load_themes() to match exactly "/admin" or the "/admin/" prefix,
but not just the "/admin" prefix because that breaks if you add an
image like "admin_photostream".
Diffstat (limited to 'modules/gallery/helpers/theme.php')
-rw-r--r-- | modules/gallery/helpers/theme.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/gallery/helpers/theme.php b/modules/gallery/helpers/theme.php index da57a37e..5a3a328a 100644 --- a/modules/gallery/helpers/theme.php +++ b/modules/gallery/helpers/theme.php @@ -38,7 +38,8 @@ class theme_Core { if (!(identity::active_user()->admin && $theme_name = $input->get("theme"))) { $theme_name = module::get_var( "gallery", - !strncmp($path, "/admin", 6) ? "active_admin_theme" : "active_site_theme"); + $path == "/admin" || !strncmp($path, "/admin/", 7) ? + "active_admin_theme" : "active_site_theme"); } $modules = Kohana::config("core.modules"); array_unshift($modules, THEMEPATH . $theme_name); |