diff options
Diffstat (limited to 'application')
-rw-r--r-- | application/ApplicationUtils.php | 3 | ||||
-rw-r--r-- | application/api/ApiUtils.php | 4 |
2 files changed, 7 insertions, 0 deletions
diff --git a/application/ApplicationUtils.php b/application/ApplicationUtils.php index 7fe3cb32..3aa21829 100644 --- a/application/ApplicationUtils.php +++ b/application/ApplicationUtils.php | |||
@@ -150,6 +150,8 @@ class ApplicationUtils | |||
150 | * @param string $minVersion minimum PHP required version | 150 | * @param string $minVersion minimum PHP required version |
151 | * @param string $curVersion current PHP version (use PHP_VERSION) | 151 | * @param string $curVersion current PHP version (use PHP_VERSION) |
152 | * | 152 | * |
153 | * @return bool true on success | ||
154 | * | ||
153 | * @throws Exception the PHP version is not supported | 155 | * @throws Exception the PHP version is not supported |
154 | */ | 156 | */ |
155 | public static function checkPHPVersion($minVersion, $curVersion) | 157 | public static function checkPHPVersion($minVersion, $curVersion) |
@@ -163,6 +165,7 @@ class ApplicationUtils | |||
163 | ); | 165 | ); |
164 | throw new Exception(sprintf($msg, $minVersion)); | 166 | throw new Exception(sprintf($msg, $minVersion)); |
165 | } | 167 | } |
168 | return true; | ||
166 | } | 169 | } |
167 | 170 | ||
168 | /** | 171 | /** |
diff --git a/application/api/ApiUtils.php b/application/api/ApiUtils.php index 1e3ac02e..5ac07c4d 100644 --- a/application/api/ApiUtils.php +++ b/application/api/ApiUtils.php | |||
@@ -15,6 +15,8 @@ class ApiUtils | |||
15 | * @param string $token JWT token extracted from the headers. | 15 | * @param string $token JWT token extracted from the headers. |
16 | * @param string $secret API secret set in the settings. | 16 | * @param string $secret API secret set in the settings. |
17 | * | 17 | * |
18 | * @return bool true on success | ||
19 | * | ||
18 | * @throws ApiAuthorizationException the token is not valid. | 20 | * @throws ApiAuthorizationException the token is not valid. |
19 | */ | 21 | */ |
20 | public static function validateJwtToken($token, $secret) | 22 | public static function validateJwtToken($token, $secret) |
@@ -45,6 +47,8 @@ class ApiUtils | |||
45 | ) { | 47 | ) { |
46 | throw new ApiAuthorizationException('Invalid JWT issued time'); | 48 | throw new ApiAuthorizationException('Invalid JWT issued time'); |
47 | } | 49 | } |
50 | |||
51 | return true; | ||
48 | } | 52 | } |
49 | 53 | ||
50 | /** | 54 | /** |