Skip to content

Commit a6fcf13

Browse files
committed
Fixed PHPDocumentation
Our application was expecting a boolean to be returned by the auth() function. However, this seems to have been changed overtime. How is determined whether an authentication is successful? It seems the only way is to use 'checkToken()' after authentication. It would be better to have 'setToken()' return a boolean, however this might break other stuff that depends on the $this being returned now...
1 parent c6ddcdc commit a6fcf13

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

CloudControl/API.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ public function requiresToken() {
120120
* @throws ThrottledError
121121
* @throws CCException
122122
*
123-
* @return boolean
123+
* @return $this
124124
*/
125125
public function auth($email, $password) {
126126
$request = new Request($this->_url);
@@ -150,7 +150,7 @@ public function checkToken($token) {
150150
*
151151
* @param string $token token to set
152152
*
153-
* @return void
153+
* @return $this
154154
*/
155155
public function setToken($token) {
156156
if ($this->checkToken($token)) {

0 commit comments

Comments
 (0)