Skip to content

Commit

Permalink
Fix failed login returns as suggested in issue #8
Browse files Browse the repository at this point in the history
  • Loading branch information
godsgood33 committed Dec 23, 2022
1 parent da11003 commit a4407c8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/jc21/PlexApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -549,6 +549,9 @@ public function call($path, $params = [], $method = self::GET, $isLoginCall = fa
{
if (!$this->token && !$isLoginCall) {
$this->call('https://plex.tv/users/sign_in.xml', [], self::POST, true);
if (!$this->token) {
return false;
}
}

if ($isLoginCall) {
Expand Down

0 comments on commit a4407c8

Please sign in to comment.