From cd52f92def16e676c2458a32d2b8c8f8a7839f06 Mon Sep 17 00:00:00 2001 From: chris Date: Wed, 25 Jan 2006 01:01:25 +0100 Subject: oo auth update - remove legacy auth remnants, add auth->canDo darcs-hash:20060125000125-9b6ab-9853f11e04d8ea93235317fa8137cef079eb2641.gz --- inc/template.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'inc/template.php') diff --git a/inc/template.php b/inc/template.php index 7fc824bd5..f12788834 100644 --- a/inc/template.php +++ b/inc/template.php @@ -304,6 +304,7 @@ function tpl_button($type){ global $NS; global $INFO; global $conf; + global $auth; switch($type){ case 'edit': @@ -357,7 +358,7 @@ function tpl_button($type){ print html_btn('backlink',$ID,'',array('do' => 'backlink')); break; case 'profile': - if(($_SERVER['REMOTE_USER']) && auth_canDo('modifyUser') && ($ACT!='profile')){ + if(($_SERVER['REMOTE_USER']) && $auth->canDo('modifyUser') && ($ACT!='profile')){ print html_btn('profile',$ID,'',array('do' => 'profile')); } break; @@ -392,6 +393,7 @@ function tpl_actionlink($type,$pre='',$suf=''){ global $ACT; global $conf; global $lang; + global $auth; switch($type){ case 'edit': @@ -464,7 +466,7 @@ function tpl_actionlink($type,$pre='',$suf=''){ tpl_link(wl($ID,'do=backlink'),$pre.$lang['btn_backlink'].$suf, 'class="action backlink"'); break; case 'profile': - if(($_SERVER['REMOTE_USER']) && auth_canDo('modifyUser') && ($ACT!='profile')){ + if(($_SERVER['REMOTE_USER']) && $auth->canDo('modifyUser') && ($ACT!='profile')){ tpl_link(wl($ID,'do=profile'),$pre.$lang['btn_profile'].$suf, 'class="action profile"'); } break; -- cgit v1.2.3