X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=plugins%2FCasAuthentication%2FCasAuthenticationPlugin.php;h=7f467173b0766616d5f3d53575a8ca2520c42e77;hb=HEAD;hp=3196bd94a7a622f6d0e186b698e0a8ea0d297040;hpb=c0bb1a57984266024e8e5a968c0f3a3b54befff6;p=quix0rs-gnu-social.git diff --git a/plugins/CasAuthentication/CasAuthenticationPlugin.php b/plugins/CasAuthentication/CasAuthenticationPlugin.php index 3196bd94a7..7f467173b0 100644 --- a/plugins/CasAuthentication/CasAuthenticationPlugin.php +++ b/plugins/CasAuthentication/CasAuthenticationPlugin.php @@ -54,13 +54,13 @@ class CasAuthenticationPlugin extends AuthenticationPlugin case 'phpCAS': require_once(INSTALLDIR.'/plugins/CasAuthentication/extlib/CAS.php'); return false; - case 'CasloginAction': - require_once(INSTALLDIR.'/plugins/CasAuthentication/' . strtolower(mb_substr($cls, 0, -6)) . '.php'); - return false; } + + // if it's not our exception, try standard places + return parent::onAutoload($cls); } - function onArgsInitialize(&$args) + function onArgsInitialize(array &$args) { if($this->takeOverLogin && $args['action'] == 'login') { @@ -125,12 +125,15 @@ class CasAuthenticationPlugin extends AuthenticationPlugin function onInitializePlugin(){ parent::onInitializePlugin(); if(!isset($this->server)){ + // TRANS: Exception thrown when the CAS Authentication plugin has been configured incorrectly. throw new Exception(_m("Specifying a server is required.")); } if(!isset($this->port)){ + // TRANS: Exception thrown when the CAS Authentication plugin has been configured incorrectly. throw new Exception(_m("Specifying a port is required.")); } if(!isset($this->path)){ + // TRANS: Exception thrown when the CAS Authentication plugin has been configured incorrectly. throw new Exception(_m("Specifying a path is required.")); } //These values need to be accessible to a action object @@ -144,10 +147,10 @@ class CasAuthenticationPlugin extends AuthenticationPlugin $casSettings['takeOverLogin']=$this->takeOverLogin; } - function onPluginVersion(&$versions) + function onPluginVersion(array &$versions) { $versions[] = array('name' => 'CAS Authentication', - 'version' => STATUSNET_VERSION, + 'version' => GNUSOCIAL_VERSION, 'author' => 'Craig Andrews', 'homepage' => 'http://status.net/wiki/Plugin:CasAuthentication', // TRANS: Plugin description. CAS is Central Authentication Service.