From a7d505f29216bfec49e238fcb7e792435f5e6897 Mon Sep 17 00:00:00 2001 From: Chris Hallberg <crhallberg@gmail.com> Date: Tue, 22 Apr 2014 15:16:39 -0400 Subject: [PATCH] Checkstyles. --- module/VuDL/src/VuDL/Connection/Fedora.php | 5 +++-- module/VuDL/src/VuDL/Connection/Solr.php | 5 +++-- module/VuFind/src/VuFind/Auth/Database.php | 8 +++++--- module/VuFind/src/VuFind/Auth/Manager.php | 17 ++++++++++------- .../VuFind/Controller/MyResearchController.php | 2 ++ module/VuFind/src/VuFind/Db/Table/User.php | 2 ++ 6 files changed, 25 insertions(+), 14 deletions(-) diff --git a/module/VuDL/src/VuDL/Connection/Fedora.php b/module/VuDL/src/VuDL/Connection/Fedora.php index 4fdabca5a63..3fb1ad0c49e 100644 --- a/module/VuDL/src/VuDL/Connection/Fedora.php +++ b/module/VuDL/src/VuDL/Connection/Fedora.php @@ -426,8 +426,9 @@ class Fedora extends AbstractBase /** * Get copyright URL and compare it to special cases from VuDL.ini * - * @param array $setLicenses ids are urls, then abbrev - * parsed in details.phtml later + * @param array $id record id + * @param array $setLicenses ids are strings to match urls to, + * the values are abbreviations. Parsed in details.phtml later. * * @return array */ diff --git a/module/VuDL/src/VuDL/Connection/Solr.php b/module/VuDL/src/VuDL/Connection/Solr.php index 175bb3075e9..fc0a803fd85 100644 --- a/module/VuDL/src/VuDL/Connection/Solr.php +++ b/module/VuDL/src/VuDL/Connection/Solr.php @@ -297,8 +297,9 @@ class Solr extends AbstractBase /** * Get copyright URL and compare it to special cases from VuDL.ini * - * @param array $setLicenses ids are urls, then abbrev - * parsed in details.phtml later + * @param array $id record id + * @param array $setLicenses ids are strings to match urls to, + * the values are abbreviations. Parsed in details.phtml later. * * @return array */ diff --git a/module/VuFind/src/VuFind/Auth/Database.php b/module/VuFind/src/VuFind/Auth/Database.php index cbd231fd56b..14523c1c3ad 100644 --- a/module/VuFind/src/VuFind/Auth/Database.php +++ b/module/VuFind/src/VuFind/Auth/Database.php @@ -179,10 +179,10 @@ class Database extends AbstractBase foreach ($params as $param => $default) { $params[$param] = $request->getPost()->get($param, $default); } - + // Validate Input $this->validateUsernameAndPassword($params); - + // Create the row and send it back to the caller: $table = $this->getUserTable(); $user = $table->getByUsername($params['username'], false); @@ -200,7 +200,9 @@ class Database extends AbstractBase * Make sure username and password aren't blank * Make sure passwords match * - * @param array $params + * @param array $params request parameters + * + * @return void */ protected function validateUsernameAndPassword($params) { diff --git a/module/VuFind/src/VuFind/Auth/Manager.php b/module/VuFind/src/VuFind/Auth/Manager.php index f217c64488f..3d95d02c558 100644 --- a/module/VuFind/src/VuFind/Auth/Manager.php +++ b/module/VuFind/src/VuFind/Auth/Manager.php @@ -138,14 +138,14 @@ class Manager implements ServiceLocatorAwareInterface } } - /** + /** * Helper * * @param string $method auth method to instantiate * * @return AbstractBase */ - protected function makeAuth($method) + protected function makeAuth($method) { $manager = $this->getServiceLocator()->get('VuFind\AuthPluginManager'); $auth = $manager->get($method); @@ -172,7 +172,7 @@ class Manager implements ServiceLocatorAwareInterface /** * Does the current configuration support password recovery? * - * @param string $authMethod optional; check this auth method rather than + * @param string $authMethod optional; check this auth method rather than * the one in config file * * @return bool @@ -192,6 +192,9 @@ class Manager implements ServiceLocatorAwareInterface /** * Is new passwords currently allowed? * + * @param string $authMethod optional; check this auth method rather than + * the one in config file + * * @return bool */ public function supportsPasswordChange($authMethod=null) @@ -231,7 +234,7 @@ class Manager implements ServiceLocatorAwareInterface } /** - * Does the current auth class allow for authentication from more than + * Does the current auth class allow for authentication from more than * one auth method? (e.g. choiceauth) * If so return an array that lists the classes for the methods allowed. * @@ -248,7 +251,7 @@ class Manager implements ServiceLocatorAwareInterface } /** - * Does the current auth class allow for authentication from more than + * Does the current auth class allow for authentication from more than * one target? (e.g. MultiILS) * If so return an array that lists the targets. * @@ -262,7 +265,7 @@ class Manager implements ServiceLocatorAwareInterface } /** - * Does the current auth class allow for authentication from more than + * Does the current auth class allow for authentication from more than * one target? (e.g. MultiILS) * If so return the default target. * @@ -576,7 +579,7 @@ class Manager implements ServiceLocatorAwareInterface * * @return void */ - public function setActiveAuthClass($method) + public function setActiveAuthClass($method) { $this->authToProxy = $method; $this->authProxied = false; diff --git a/module/VuFind/src/VuFind/Controller/MyResearchController.php b/module/VuFind/src/VuFind/Controller/MyResearchController.php index a78ff7f3cd6..427e218abcb 100644 --- a/module/VuFind/src/VuFind/Controller/MyResearchController.php +++ b/module/VuFind/src/VuFind/Controller/MyResearchController.php @@ -1347,6 +1347,8 @@ class MyResearchController extends AbstractBase /** * Helper function for verification hashes * + * @param string $hash User-unique hash string from request + * * @return int age in seconds */ protected function getHashAge($hash) diff --git a/module/VuFind/src/VuFind/Db/Table/User.php b/module/VuFind/src/VuFind/Db/Table/User.php index 0f91d6a906d..b65942e52a7 100644 --- a/module/VuFind/src/VuFind/Db/Table/User.php +++ b/module/VuFind/src/VuFind/Db/Table/User.php @@ -97,6 +97,8 @@ class User extends Gateway /** * Return a row by a verification hash * + * @param string $hash User-unique hash string + * * @return mixed */ public function getByVerifyHash($hash) -- GitLab