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

This commit is contained in:
Tim Almdal
2009-10-22 13:09:20 -07:00
parent 4cb9ec1d6d
commit 3c936d661a
60 changed files with 628 additions and 512 deletions

View File

@@ -69,7 +69,7 @@ class Admin_Users_Controller extends Admin_Controller {
public function delete_user($id) {
access::verify_csrf();
if ($id == Session::active_user()->id || $id == user::guest()->id) {
if ($id == identity::active_user()->id || $id == user::guest()->id) {
access::forbidden();
}
@@ -136,7 +136,7 @@ class Admin_Users_Controller extends Admin_Controller {
}
// An admin can change the admin status for any user but themselves
if ($user->id != Session::active_user()->id) {
if ($user->id != identity::active_user()->id) {
$user->admin = $form->edit_user->admin->checked;
}
$user->save();
@@ -158,7 +158,7 @@ class Admin_Users_Controller extends Admin_Controller {
$form = $this->_get_user_edit_form_admin($user);
// Don't allow the user to control their own admin bit, else you can lock yourself out
if ($user->id == Session::active_user()->id) {
if ($user->id == identity::active_user()->id) {
$form->edit_user->admin->disabled(1);
}
print $form;