From d4902331cfaed384dece18deedab7f2c4b8aaead Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Fri, 17 Aug 2018 16:51:41 +0200 Subject: [PATCH] adding app/library/Auth/Result.php --- app/library/Auth/Result.php | 53 +++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 app/library/Auth/Result.php diff --git a/app/library/Auth/Result.php b/app/library/Auth/Result.php new file mode 100644 index 0000000..f6381aa --- /dev/null +++ b/app/library/Auth/Result.php @@ -0,0 +1,53 @@ +_code = (int) $code; + } + + /** + * Get the result code for this authentication attempt. + * + * @return int + */ + public function getCode() + { + return $this->_code; + } + + /** + * Returns true if the authentication was sucessfull, false otherwise. + * + * @return bool + */ + public function isValid() + { + return $this->_code == self::SUCCESS; + } +}