diff options
| author | Tim Almdal <tnalmdal@shaw.ca> | 2009-10-22 13:09:20 -0700 |
|---|---|---|
| committer | Tim Almdal <tnalmdal@shaw.ca> | 2009-10-22 13:11:03 -0700 |
| commit | 3c936d661a088fb43b47eb5b208958180e8f65eb (patch) | |
| tree | 1a117dc1bfe54bec44f664cbd7c5f8c93aa5e993 /modules/gallery/helpers/gallery_event.php | |
| parent | 4cb9ec1d6d37b49ebafc68d0a94d794a1acb8b28 (diff) | |
Change the name of identity library from Identity to IdentityProvider. Create a helper class called identity to simplify call the Identity Provider. Move the contents of MY_Session.php to the new helper class and remove the MY_Session class
Diffstat (limited to 'modules/gallery/helpers/gallery_event.php')
| -rw-r--r-- | modules/gallery/helpers/gallery_event.php | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/modules/gallery/helpers/gallery_event.php b/modules/gallery/helpers/gallery_event.php index 95be4813..b6afa2c8 100644 --- a/modules/gallery/helpers/gallery_event.php +++ b/modules/gallery/helpers/gallery_event.php @@ -23,11 +23,7 @@ class gallery_event_Core { * Initialization. */ static function gallery_ready() { - // Call Identity::instance() now to force the load of the user interface classes. - // Session::load_user will attempt to load the active user from the session and needs - // the user definition class, which can't be reached by Kohana's heiracrchical lookup. - Identity::instance(); - Session::load_user(); + identity::load_user(); locales::set_request_locale(); } @@ -139,7 +135,7 @@ class gallery_event_Core { } } - if (Session::active_user()->admin) { + if (identity::active_user()->admin) { $menu->append($admin_menu = Menu::factory("submenu") ->id("admin_menu") ->label(t("Admin"))); @@ -191,7 +187,7 @@ class gallery_event_Core { ->id("sidebar") ->label(t("Manage Sidebar")) ->url(url::site("admin/sidebar")))); - if (count(Identity::providers()) > 1) { + if (count(identity::providers()) > 1) { $menu ->append(Menu::factory("submenu") ->id("identity_menu") |
