Skip to content

Commit a2ff29e

Browse files
committed
linter fixes
1 parent 1ed00d0 commit a2ff29e

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

src/PubNub/CryptoModule.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ public function parseInput(string | object $input): string
178178
throw new PubNubResponseParsingException("Decryption error: message is not a string or object");
179179
}
180180

181-
if (strlen($input) == '') {
181+
if (trim($input) == '') {
182182
throw new PubNubResponseParsingException("Decryption error: message is empty");
183183
}
184184
return $input;

src/PubNub/Endpoints/Access/GrantToken.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,17 @@
22

33
namespace PubNub\Endpoints\Access;
44

5+
56
use PubNub\Endpoints\Endpoint;
67
use PubNub\Exceptions\PubNubValidationException;
7-
use PubNub\Models\Consumer\AccessManager\PNAccessManagerGrantResult;
88
use PubNub\PubNubUtil;
99
use PubNub\Enums\PNHttpMethod;
1010
use PubNub\Enums\PNOperationType;
1111
use PubNub\Exceptions\PubNubTokenParseException;
1212
use PubNub\Models\Consumer\AccessManager\PNAccessManagerTokenResult;
1313
use PubNub\PubNubCborDecode;
1414

15+
1516
class GrantToken extends Endpoint
1617
{
1718
protected const PATH = '/v3/pam/%s/grant';
@@ -239,16 +240,16 @@ public function buildPath()
239240
/**
240241
* @return string
241242
*/
242-
public function sync(): string
243+
public function sync() : string
243244
{
244245
return parent::sync();
245246
}
246247

247248
/**
248249
* @param string $token
249-
* @return : string
250+
* @return string
250251
*/
251-
public function createResponse($response): string
252+
public function createResponse($response) : string
252253
{
253254
return $response['data']['token'];
254255
}

src/PubNub/Models/Consumer/FileSharing/PNGetFileDownloadURLResult.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
namespace PubNub\Models\Consumer\FileSharing;
44

5+
56
class PNGetFileDownloadURLResult
67
{
78
protected string $fileUrl;
@@ -13,7 +14,7 @@ public function __construct($result)
1314

1415
public function __toString()
1516
{
16-
return "Get file URL success with URL: %s" % $this->fileUrl;
17+
return "Get file URL success with URL: {$this->fileUrl}";
1718
}
1819

1920
public function getFileUrl()

0 commit comments

Comments
 (0)