Skip to content

Commit

Permalink
fix(Resource) cast return type to expected bool
Browse files Browse the repository at this point in the history
  • Loading branch information
lucatume committed Sep 3, 2024
1 parent 3577725 commit d45869f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Uplink/Resources/Resource.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ public function is_using_oauth(): bool {
* @return bool Whether the resource requires a license key for OAuth.
*/
public function oauth_requires_license_key(): bool {
return $this->oauth & self::OAUTH_REQUIRES_LICENSE_KEY;
return (bool)$this->oauth & self::OAUTH_REQUIRES_LICENSE_KEY;

Check failure on line 201 in src/Uplink/Resources/Resource.php

View workflow job for this annotation

GitHub Actions / phpstan

Method StellarWP\Uplink\Resources\Resource::oauth_requires_license_key() should return bool but returns int<0, 2>.
}

/**
Expand Down

0 comments on commit d45869f

Please sign in to comment.