From 9ce0efd60fe3c67658b828cb41a36f332b7918c1 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Tue, 7 Jul 2009 18:20:26 -0600 Subject: [PATCH] Auth:: -> Horde_Auth:: --- babel/lib/Babel.php | 4 +- babel/view.php | 2 +- chora/lib/Chora.php | 2 +- drag_n_drop_portal/index.php | 2 +- drag_n_drop_portal/save.php | 2 +- fima/account.php | 12 ++--- fima/accounts.php | 2 +- fima/config/prefs.php.dist | 2 +- fima/ledgers/create.php | 2 +- fima/ledgers/delete.php | 6 +-- fima/ledgers/edit.php | 4 +- fima/ledgers/index.php | 2 +- fima/lib/Block/summary.php | 2 +- fima/lib/Fima.php | 16 +++---- fima/lib/Forms/DeleteLedger.php | 8 ++-- fima/postings.php | 10 ++-- fima/templates/accounts/accounts.inc | 4 +- fima/templates/prefs/ledgerselect.inc | 2 +- folks/account/approve.php | 12 ++--- folks/account/renew.php | 12 ++--- folks/account/resetpassword.php | 16 +++---- folks/account/signup.php | 6 +-- folks/account/tabs.php | 2 +- folks/account/username.php | 2 +- folks/config/hooks.php.dist | 13 +++-- folks/edit/activity.php | 2 +- folks/edit/comments.php | 8 ++-- folks/edit/edit.php | 6 +-- folks/edit/friends/add.php | 10 ++-- folks/edit/friends/approve.php | 8 ++-- folks/edit/friends/invite.php | 6 +-- folks/edit/friends/reject.php | 10 ++-- folks/edit/password.php | 14 +++--- folks/edit/privacy.php | 2 +- folks/edit/tabs.php | 2 +- folks/friends.php | 4 +- folks/lib/Auth/folks.php | 55 ++++++++++------------ folks/lib/Block/my_comments.php | 6 +-- folks/lib/Driver.php | 34 ++++++------- folks/lib/Driver/sql.php | 14 +++--- folks/lib/Folks.php | 6 +-- folks/lib/Friends.php | 10 ++-- folks/lib/Friends/prefs.php | 2 +- folks/lib/Friends/shared.php | 8 ++-- folks/lib/Notification.php | 8 ++-- folks/lib/api.php | 12 ++--- folks/login.php | 16 +++---- folks/perms.php | 14 +++--- folks/report.php | 2 +- folks/rss/activity.php | 4 +- folks/rss/friends.php | 4 +- folks/rss/know.php | 6 +-- folks/scripts/mail-filter.php | 3 +- folks/scripts/mail.php | 4 +- folks/scripts/online.php | 4 +- folks/search.php | 4 +- folks/templates/common-header.inc | 2 +- folks/templates/user/authenticated.php | 2 +- folks/templates/user/user.php | 18 +++---- folks/user.php | 8 ++-- framework/Rdo/www/crud.php | 2 +- framework/Rdo/www/index.php | 2 +- imp/config/hooks.php.dist | 6 +-- imp/lib/Auth/{imp.php => Imp.php} | 25 +++++----- imp/lib/Compose.php | 2 +- imp/lib/Folder.php | 2 +- imp/lib/IMP.php | 14 +++--- imp/lib/Imap/Tree.php | 2 +- .../LoginTasks/Task/DeleteAttachmentsMonthly.php | 2 +- imp/lib/MIMP.php | 2 +- imp/lib/Maillog.php | 2 +- imp/lib/Notification/Listener/Status.php | 2 +- imp/lib/Sentmail/sql.php | 6 +-- imp/lib/Session.php | 14 +++--- imp/lib/Spam.php | 6 +-- imp/lib/base.php | 2 +- imp/login.php | 35 +++++++------- imp/message.php | 2 +- imp/redirect.php | 8 ++-- imp/rss.php | 4 +- imp/scripts/custom_login.php | 2 +- imp/templates/javascript_defs_dimp.php | 2 +- ingo/lib/Ingo.php | 18 +++---- ingo/lib/api.php | 2 +- ingo/lib/base.php | 8 ++-- ingo/scripts/ingo-postfix-policyd | 2 +- ingo/scripts/upgrades/convert_prefs_to_sql.php | 5 +- ingo/vacation.php | 2 +- jeta/lib/Applet/jta.php | 2 +- jeta/lib/Applet/sshtools.php | 2 +- kastalia/main.php | 6 +-- koward/lib/Koward.php | 6 +-- koward/lib/Koward/Cli.php | 2 +- koward/lib/Koward/Controller/Application.php | 8 ++-- koward/lib/Koward/Controller/IndexController.php | 8 ++-- koward/www/horde/config/prefs.php.dist | 2 +- kronolith/add.php | 10 ++-- kronolith/ajax.php | 2 +- kronolith/attendees.php | 4 +- kronolith/calendars/create.php | 2 +- kronolith/calendars/delete.php | 6 +-- kronolith/calendars/edit.php | 4 +- kronolith/calendars/index.php | 2 +- kronolith/calendars/info.php | 2 +- kronolith/calendars/remote_edit.php | 4 +- kronolith/calendars/remote_subscribe.php | 2 +- kronolith/calendars/remote_unsubscribe.php | 2 +- kronolith/config/prefs.php.dist | 2 +- kronolith/contacts.php | 2 +- kronolith/data.php | 2 +- kronolith/delete.php | 2 +- kronolith/edit.php | 22 ++++----- kronolith/event.php | 2 +- kronolith/feed/index.php | 6 +-- kronolith/index.php | 2 +- kronolith/lib/Block/month.php | 2 +- kronolith/lib/Block/monthlist.php | 2 +- kronolith/lib/Block/prevmonthlist.php | 2 +- kronolith/lib/Block/summary.php | 2 +- kronolith/lib/Block/tree_alarms.php | 2 +- kronolith/lib/Driver/Ical.php | 2 +- kronolith/lib/Driver/Sql.php | 26 +++++----- kronolith/lib/Event.php | 24 +++++----- kronolith/lib/Event/Kolab.php | 4 +- kronolith/lib/Forms/DeleteCalendar.php | 8 ++-- kronolith/lib/Forms/EditRemoteCalendar.php | 2 +- kronolith/lib/Forms/SubscribeRemoteCalendar.php | 2 +- kronolith/lib/Imple/TagActions.php | 8 ++-- kronolith/lib/Kronolith.php | 42 ++++++++--------- kronolith/lib/LoginTasks/Task/PurgeEvents.php | 2 +- kronolith/lib/Notification/Listener/Status.php | 2 +- kronolith/lib/Storage.php | 4 +- kronolith/lib/Storage/kolab.php | 2 +- kronolith/lib/Storage/sql.php | 4 +- kronolith/lib/Tagger.php | 4 +- kronolith/lib/Views/EditEvent.php | 2 +- kronolith/lib/Views/Event.php | 4 +- kronolith/lib/api.php | 18 +++---- kronolith/lib/prefs.php | 2 +- kronolith/perms.php | 14 +++--- kronolith/scripts/import_icals.php | 5 +- kronolith/scripts/import_squirrelmail_calendar.php | 45 +++++++++--------- kronolith/search.php | 2 +- kronolith/templates/edit/edit.inc | 2 +- kronolith/templates/panel.inc | 8 ++-- kronolith/templates/perms/perms.inc | 10 ++-- kronolith/templates/prefs/fb_cals_select.inc | 2 +- kronolith/templates/prefs/shareselect.inc | 2 +- news/add.php | 10 ++-- news/admin/tabs.php | 2 +- news/delete.php | 2 +- news/delete_file.php | 2 +- news/edit.php | 4 +- news/files.php | 6 +-- news/lib/Block/my_comments.php | 4 +- news/lib/Categories.php | 10 ++-- news/lib/Driver.php | 4 +- news/lib/Driver/sql.php | 4 +- news/lib/Forms/Search.php | 2 +- news/lib/News.php | 6 +-- news/lib/Search.php | 2 +- news/mail.php | 4 +- news/reads.php | 2 +- news/templates/edit/row.php | 2 +- skoli/add.php | 2 +- skoli/classes/create.php | 2 +- skoli/classes/delete.php | 4 +- skoli/classes/edit.php | 4 +- skoli/classes/index.php | 2 +- skoli/entry.php | 8 ++-- skoli/lib/Driver/sql.php | 2 +- skoli/lib/Forms/DeleteClass.php | 2 +- skoli/lib/Forms/Entry.php | 2 +- skoli/lib/Skoli.php | 12 ++--- skoli/list.php | 2 +- skoli/templates/list/headers.inc | 2 +- skoli/templates/panel.inc | 6 +-- 177 files changed, 560 insertions(+), 580 deletions(-) rename imp/lib/Auth/{imp.php => Imp.php} (75%) diff --git a/babel/lib/Babel.php b/babel/lib/Babel.php index 08d7c61f2..cee2459ad 100644 --- a/babel/lib/Babel.php +++ b/babel/lib/Babel.php @@ -164,7 +164,7 @@ class Babel { { global $perms; - $userId = Auth::getAuth(); + $userId = Horde_Auth::getAuth(); $admin = ($userId == 'admin') ? true : false; if ($admin || !$perms->exists('babel:' . $permission)) { @@ -176,7 +176,7 @@ class Babel { switch ($filter) { case 'tabs': if ($perm) { - $allowed = $perms->hasPermission('babel:' . $permission, Auth::getAuth(), $perm); + $allowed = $perms->hasPermission('babel:' . $permission, Horde_Auth::getAuth(), $perm); } break; } diff --git a/babel/view.php b/babel/view.php index f05b15aea..3ed8e6ae5 100644 --- a/babel/view.php +++ b/babel/view.php @@ -341,7 +341,7 @@ if (!$app) { if ($editmode && $cstring == $encstr) { // Lock the current item for 5 minutes - $locks->setLock(Auth::getAuth(), md5($encstr), $lockscope, 300); + $locks->setLock(Horde_Auth::getAuth(), md5($encstr), $lockscope, 300); echo '
'; echo ''; diff --git a/chora/lib/Chora.php b/chora/lib/Chora.php index e20a5b850..b2084dc15 100644 --- a/chora/lib/Chora.php +++ b/chora/lib/Chora.php @@ -318,7 +318,7 @@ class Chora static public function checkPerms($key) { return (!$GLOBALS['perms']->exists('chora:sourceroots:' . $key) || - $GLOBALS['perms']->hasPermission('chora:sourceroots:' . $key, Auth::getAuth(), PERMS_READ | PERMS_SHOW)); + $GLOBALS['perms']->hasPermission('chora:sourceroots:' . $key, Horde_Auth::getAuth(), PERMS_READ | PERMS_SHOW)); } /** diff --git a/drag_n_drop_portal/index.php b/drag_n_drop_portal/index.php index 7bfb3def6..db2068dcd 100644 --- a/drag_n_drop_portal/index.php +++ b/drag_n_drop_portal/index.php @@ -15,7 +15,7 @@ require_once HORDE_BASE . '/lib/base.php'; require_once 'Horde/Loader.php'; require_once './lib/Block/Layout/View/js.php'; -if (!Auth::isAuthenticated()) { +if (!Horde_Auth::isAuthenticated()) { Horde::authenticationFailureRedirect(); } diff --git a/drag_n_drop_portal/save.php b/drag_n_drop_portal/save.php index 46b6cbf4a..8ae30ed8f 100644 --- a/drag_n_drop_portal/save.php +++ b/drag_n_drop_portal/save.php @@ -14,7 +14,7 @@ define('HORDE_BASE', dirname(__FILE__) . '/..'); require_once HORDE_BASE . '/lib/base.php'; require_once 'Horde/Loader.php'; -if (!Auth::isAuthenticated()) { +if (!Horde_Auth::isAuthenticated()) { Horde::authenticationFailureRedirect(); } diff --git a/fima/account.php b/fima/account.php index cdfb05087..c336e5b07 100644 --- a/fima/account.php +++ b/fima/account.php @@ -69,7 +69,7 @@ case 'add_account': case 'modify_account': $account_id = $vars->get('account'); - if (!$share->hasPermission(Auth::getAuth(), PERMS_EDIT)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT)) { $notification->push(_("Access denied editing account."), 'horde.error'); } else { $account = Fima::getAccount($account_id); @@ -79,7 +79,7 @@ case 'modify_account': $vars = new Horde_Variables($account); $vars->set('actionID', 'save_account'); $vars->set('number_new', $vars->get('number')); - $form = new Fima_AccountForm($vars, sprintf(_("Edit: %s"), trim($account['number'] . ' ' . $account['name'])), $share->hasPermission(Auth::getAuth(), PERMS_DELETE)); + $form = new Fima_AccountForm($vars, sprintf(_("Edit: %s"), trim($account['number'] . ' ' . $account['name'])), $share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE)); break; } } @@ -102,7 +102,7 @@ case 'save_account': } $form->getInfo($vars, $info); - if (!$share->hasPermission(Auth::getAuth(), PERMS_EDIT)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT)) { $notification->push(sprintf(_("Access denied saving account to %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('accounts.php', true)); exit; @@ -171,7 +171,7 @@ case 'save_account': case 'delete_account': $account_id = $vars->get('account'); - if (!$share->hasPermission(Auth::getAuth(), PERMS_DELETE)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE)) { $notification->push(_("Access denied deleting account."), 'horde.error'); } else { $account = Fima::getAccount($account_id); @@ -182,7 +182,7 @@ case 'delete_account': $vars->set('actionID', 'purge_account'); $vars->set('dssubaccounts', array('type' => 'none', 'account' => $account_id)); $vars->set('dspostings', array('type' => 'delete', 'account' => $account_id)); - $form = new Fima_AccountDeleteForm($vars, sprintf(_("Delete: %s"), trim($account['number'] . ' ' . $account['name'])), $share->hasPermission(Auth::getAuth(), PERMS_EDIT)); + $form = new Fima_AccountDeleteForm($vars, sprintf(_("Delete: %s"), trim($account['number'] . ' ' . $account['name'])), $share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT)); break; } } @@ -205,7 +205,7 @@ case 'purge_account': } $form->getInfo($vars, $info); - if (!$share->hasPermission(Auth::getAuth(), PERMS_DELETE)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE)) { $notification->push(sprintf(_("Access denied deleting account from %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('accounts.php', true)); exit; diff --git a/fima/accounts.php b/fima/accounts.php index 011aa0604..5ecad29e0 100644 --- a/fima/accounts.php +++ b/fima/accounts.php @@ -25,7 +25,7 @@ if (is_a($share, 'PEAR_Error')) { $actionID = Horde_Util::getFormData('actionID'); switch ($actionID) { case 'delete_all': - if (!$share->hasPermission(Auth::getAuth(), PERMS_DELETE)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE)) { $notification->push(_("Access denied deleting all accounts and postings."), 'horde.error'); } else { $storage = &Fima_Driver::singleton($ledger); diff --git a/fima/config/prefs.php.dist b/fima/config/prefs.php.dist index 59fc274bb..2b46ea29c 100644 --- a/fima/config/prefs.php.dist +++ b/fima/config/prefs.php.dist @@ -29,7 +29,7 @@ $_prefs['ledgerselect'] = array('type' => 'special'); // active ledger // Set locked to true if you don't want users to have multiple ledgers. $_prefs['active_ledger'] = array( - 'value' => Auth::getAuth() ? Auth::getAuth() : 0, + 'value' => Horde_Auth::getAuth() ? Horde_Auth::getAuth() : 0, 'locked' => false, 'shared' => true, 'type' => 'implicit' diff --git a/fima/ledgers/create.php b/fima/ledgers/create.php index 2a61d93b9..fabfff275 100644 --- a/fima/ledgers/create.php +++ b/fima/ledgers/create.php @@ -14,7 +14,7 @@ require_once FIMA_BASE . '/lib/Forms/CreateLedger.php'; // Exit if this isn't an authenticated user or if the user can't // create new task lists (default share is locked). -if (!Auth::getAuth() || $prefs->isLocked('active_ledger')) { +if (!Horde_Auth::getAuth() || $prefs->isLocked('active_ledger')) { header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; } diff --git a/fima/ledgers/delete.php b/fima/ledgers/delete.php index e561d6110..85268ee8b 100644 --- a/fima/ledgers/delete.php +++ b/fima/ledgers/delete.php @@ -13,14 +13,14 @@ require_once FIMA_BASE . '/lib/base.php'; require_once FIMA_BASE . '/lib/Forms/DeleteLedger.php'; // Exit if this isn't an authenticated user. -if (!Auth::getAuth()) { +if (!Horde_Auth::getAuth()) { header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; } $vars = Horde_Variables::getDefaultVariables(); $ledger_id = $vars->get('l'); -if ($ledger_id == Auth::getAuth()) { +if ($ledger_id == Horde_Auth::getAuth()) { $notification->push(_("This ledger cannot be deleted."), 'horde.warning'); header('Location: ' . Horde::applicationUrl('ledgers/', true)); exit; @@ -31,7 +31,7 @@ if (is_a($ledger, 'PEAR_Error')) { $notification->push($ledger, 'horde.error'); header('Location: ' . Horde::applicationUrl('ledgers/', true)); exit; -} elseif ($ledger->get('owner') != Auth::getAuth()) { +} elseif ($ledger->get('owner') != Horde_Auth::getAuth()) { $notification->push(_("You are not allowed to delete this ledger."), 'horde.error'); header('Location: ' . Horde::applicationUrl('ledgers/', true)); exit; diff --git a/fima/ledgers/edit.php b/fima/ledgers/edit.php index d7b2ddd83..f2ce3721f 100644 --- a/fima/ledgers/edit.php +++ b/fima/ledgers/edit.php @@ -13,7 +13,7 @@ require_once FIMA_BASE . '/lib/base.php'; require_once FIMA_BASE . '/lib/Forms/EditLedger.php'; // Exit if this isn't an authenticated user. -if (!Auth::getAuth()) { +if (!Horde_Auth::getAuth()) { header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; } @@ -24,7 +24,7 @@ if (is_a($ledger, 'PEAR_Error')) { $notification->push($ledger, 'horde.error'); header('Location: ' . Horde::applicationUrl('ledgers/', true)); exit; -} elseif ($ledger->get('owner') != Auth::getAuth()) { +} elseif ($ledger->get('owner') != Horde_Auth::getAuth()) { $notification->push(_("You are not allowed to change this ledger."), 'horde.error'); header('Location: ' . Horde::applicationUrl('ledgers/', true)); exit; diff --git a/fima/ledgers/index.php b/fima/ledgers/index.php index 14848d785..b8bb9e35c 100644 --- a/fima/ledgers/index.php +++ b/fima/ledgers/index.php @@ -12,7 +12,7 @@ require_once FIMA_BASE . '/lib/base.php'; /* Exit if this isn't an authenticated user. */ -if (!Auth::getAuth()) { +if (!Horde_Auth::getAuth()) { require FIMA_BASE . '/postings.php'; exit; } diff --git a/fima/lib/Block/summary.php b/fima/lib/Block/summary.php index dd9c046e7..eae015a80 100644 --- a/fima/lib/Block/summary.php +++ b/fima/lib/Block/summary.php @@ -37,7 +37,7 @@ class Horde_Block_fima_summary extends Horde_Block { 'show_ledger' => array( 'type' => 'enum', 'name' => _("Show summary of this ledger"), - 'default' => Auth::getAuth(), + 'default' => Horde_Auth::getAuth(), 'values' => $ledgers), 'show_months' => array( 'type' => 'enum', diff --git a/fima/lib/Fima.php b/fima/lib/Fima.php index 4b4645f55..196e37a3c 100644 --- a/fima/lib/Fima.php +++ b/fima/lib/Fima.php @@ -191,7 +191,7 @@ class Fima { */ function listLedgers($owneronly = false, $permission = PERMS_SHOW) { - $ledgers = $GLOBALS['fima_shares']->listShares(Auth::getAuth(), $permission, $owneronly ? Auth::getAuth() : null); + $ledgers = $GLOBALS['fima_shares']->listShares(Horde_Auth::getAuth(), $permission, $owneronly ? Horde_Auth::getAuth() : null); if (is_a($ledgers, 'PEAR_Error')) { Horde::logMessage($ledgers, __FILE__, __LINE__, PEAR_LOG_ERR); return array(); @@ -706,7 +706,7 @@ class Fima { if (count($GLOBALS['display_ledgers']) == 0) { $ledgerss = Fima::listLedgers(true); - if (!Auth::getAuth()) { + if (!Horde_Auth::getAuth()) { /* All ledgers for guests. */ $GLOBALS['display_ledgers'] = array_keys($ledgers); } else { @@ -717,20 +717,20 @@ class Fima { } /* If the user's personal ledger doesn't exist, then create it. */ - if (!$GLOBALS['fima_shares']->exists(Auth::getAuth())) { + if (!$GLOBALS['fima_shares']->exists(Horde_Auth::getAuth())) { require_once 'Horde/Identity.php'; $identity = &Identity::singleton(); $name = $identity->getValue('fullname'); if (trim($name) == '') { - $name = Auth::removeHook(Auth::getAuth()); + $name = Horde_Auth::removeHook(Horde_Auth::getAuth()); } - $share = &$GLOBALS['fima_shares']->newShare(Auth::getAuth()); + $share = &$GLOBALS['fima_shares']->newShare(Horde_Auth::getAuth()); $share->set('name', sprintf(_("%s's Ledger"), $name)); $GLOBALS['fima_shares']->addShare($share); /* Make sure the personal ledger is displayed by default. */ - if (!in_array(Auth::getAuth(), $GLOBALS['display_ledgers'])) { - $GLOBALS['display_ledgers'][] = Auth::getAuth(); + if (!in_array(Horde_Auth::getAuth(), $GLOBALS['display_ledgers'])) { + $GLOBALS['display_ledgers'][] = Horde_Auth::getAuth(); } } } @@ -759,7 +759,7 @@ class Fima { $menu->add(Horde::applicationUrl('search.php'), _("Search"), 'search.png', $registry->getImageDir('horde')); $menu->add(Horde::applicationUrl('accounts.php'), _("_Accounts"), 'accounts.png'); - if (Auth::getAuth()) { + if (Horde_Auth::getAuth()) { $menu->add(Horde::applicationUrl('ledgers/index.php'), _("_My Ledgers"), 'accounts.png'); } diff --git a/fima/lib/Forms/DeleteLedger.php b/fima/lib/Forms/DeleteLedger.php index f80fc6886..477dbd674 100644 --- a/fima/lib/Forms/DeleteLedger.php +++ b/fima/lib/Forms/DeleteLedger.php @@ -48,7 +48,7 @@ class Fima_DeleteLedgerForm extends Horde_Form { return false; } - if ($this->_ledger->get('owner') != Auth::getAuth()) { + if ($this->_ledger->get('owner') != Horde_Auth::getAuth()) { return PEAR::raiseError(_("Permission denied")); } @@ -68,14 +68,14 @@ class Fima_DeleteLedgerForm extends Horde_Form { // Make sure we still own at least one ledger. if (count(Fima::listLedgers(true)) == 0) { // If the default share doesn't exist then create it. - if (!$GLOBALS['fima_shares']->exists(Auth::getAuth())) { + if (!$GLOBALS['fima_shares']->exists(Horde_Auth::getAuth())) { require_once 'Horde/Identity.php'; $identity = &Identity::singleton(); $name = $identity->getValue('fullname'); if (trim($name) == '') { - $name = Auth::removeHook(Auth::getAuth()); + $name = Horde_Auth::removeHook(Horde_Auth::getAuth()); } - $ledger = &$GLOBALS['fima_shares']->newShare(Auth::getAuth()); + $ledger = &$GLOBALS['fima_shares']->newShare(Horde_Auth::getAuth()); if (is_a($ledger, 'PEAR_Error')) { return; } diff --git a/fima/postings.php b/fima/postings.php index 1033ccece..f7510a7a0 100644 --- a/fima/postings.php +++ b/fima/postings.php @@ -169,7 +169,7 @@ case 'save_postings': $postingset = Horde_Util::getFormData('posting_id'); $share = &$GLOBALS['fima_shares']->getShare($ledger); - if (!$share->hasPermission(Auth::getAuth(), PERMS_EDIT)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT)) { $notification->push(sprintf(_("Access denied saving postings to %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; @@ -284,7 +284,7 @@ case 'delete_postings': $postingset = Horde_Util::getFormData('indices'); $share = &$GLOBALS['fima_shares']->getShare($ledger); - if (!$share->hasPermission(Auth::getAuth(), PERMS_DELETE)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE)) { $notification->push(sprintf(_("Access denied deleting postings from %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; @@ -315,7 +315,7 @@ case 'update_postings': $postingset = Horde_Util::getFormData('posting_id'); $share = &$GLOBALS['fima_shares']->getShare($ledger); - if (!$share->hasPermission(Auth::getAuth(), PERMS_EDIT)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT)) { $notification->push(sprintf(_("Access denied shifting postings in %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; @@ -350,11 +350,11 @@ case 'update_postings': case 'copymove_postings': $share = &$GLOBALS['fima_shares']->getShare($ledger); - if (!$share->hasPermission(Auth::getAuth(), PERMS_EDIT)) { + if (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT)) { $notification->push(sprintf(_("Access denied transfering postings in %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; - } elseif (!$share->hasPermission(Auth::getAuth(), PERMS_DELETE) && (!Horde_Util::getFormData('keep') || Horde_Util::getFormData('delete'))) { + } elseif (!$share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE) && (!Horde_Util::getFormData('keep') || Horde_Util::getFormData('delete'))) { $notification->push(sprintf(_("Access denied transfering postings in %s."), $share->get('name')), 'horde.error'); header('Location: ' . Horde::applicationUrl('postings.php', true)); exit; diff --git a/fima/templates/accounts/accounts.inc b/fima/templates/accounts/accounts.inc index bc60f3728..fe0346c5c 100644 --- a/fima/templates/accounts/accounts.inc +++ b/fima/templates/accounts/accounts.inc @@ -1,7 +1,7 @@ hasPermission(Auth::getAuth(), PERMS_EDIT); -$perm_delete = $share->hasPermission(Auth::getAuth(), PERMS_DELETE); +$perm_edit = $share->hasPermission(Horde_Auth::getAuth(), PERMS_EDIT); +$perm_delete = $share->hasPermission(Horde_Auth::getAuth(), PERMS_DELETE); ?>