From 9134ec4cca42c81c416a5890efffc5627e25eb07 Mon Sep 17 00:00:00 2001 From: Peter Date: Mon, 4 Sep 2023 18:08:49 +0800 Subject: [PATCH] Improve some stuffs about codes --- src/Client.php | 4 ++-- src/Url/AccessTokenUrl.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Client.php b/src/Client.php index f04f5dce..ba9854d0 100644 --- a/src/Client.php +++ b/src/Client.php @@ -34,7 +34,7 @@ class Client { - public const MAJOR_VERSION = 3; + final public const MAJOR_VERSION = 3; /** @var array */ private array $baseUrls; @@ -142,7 +142,7 @@ public function addImage(string $image): AddedImage try { return $this->addImageFromPath($image); - } catch (InvalidLocalFileException $e) { + } catch (InvalidLocalFileException) { // not a local file } diff --git a/src/Url/AccessTokenUrl.php b/src/Url/AccessTokenUrl.php index d7d866f5..4a7c22b4 100644 --- a/src/Url/AccessTokenUrl.php +++ b/src/Url/AccessTokenUrl.php @@ -4,7 +4,7 @@ use GuzzleHttp\Psr7\Uri; use GuzzleHttp\Psr7\Utils; -class AccessTokenUrl extends Uri +class AccessTokenUrl extends Uri implements \Stringable { private string $privateKey;