File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -27,10 +27,12 @@ class API extends RestClient
2727 *
2828 * @param string $username SinusBot username
2929 * @param string $password SinusBot password
30+ * @param string $uuid SinusBot Bot UUID
3031 * @return boolean success
3132 */
32- public function login ($ username , $ password )
33+ public function login ($ username , $ password, $ uuid = null )
3334 {
35+ $ this ->uuid = !$ uuid ?$ this ->getDefaultBot ():$ uuid ;
3436 $ login = $ this ->request ('/bot/login ' , 'POST ' , [
3537 'username ' => $ username ,
3638 'password ' => $ password ,
@@ -456,14 +458,12 @@ public function getThumbnail($thumbnail)
456458 * __construct
457459 *
458460 * @param string $url SinusBot Bot URL
459- * @param string $uuid SinusBot Bot UUID
460461 * @param string $timeout HTTP Timeout which is used to perform HTTP API requests
461462 * @return void
462463 */
463- public function __construct ($ url = 'http://127.0.0.1:8087 ' , $ uuid = null , $ timeout = 8000 )
464+ public function __construct ($ url = 'http://127.0.0.1:8087 ' , $ timeout = 8000 )
464465 {
465466 $ this ->url = $ url ;
466467 $ this ->timeout = $ timeout ;
467- $ this ->uuid = ($ uuid == null ) ? $ this ->getDefaultBot () : $ uuid ;
468468 }
469469}
You can’t perform that action at this time.
0 commit comments