From 55e862422496da6cbd7415cae7b3e91ae2dd9481 Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Mon, 2 Oct 2023 05:49:44 +0000 Subject: [PATCH] Apply fixes from StyleCI --- src/CloudflareRequest.php | 2 +- src/D1/D1Connection.php | 2 +- src/D1/D1SchemaGrammar.php | 2 +- src/D1/Pdo/D1Pdo.php | 1 - src/D1/Pdo/D1PdoStatement.php | 3 +-- src/D1/Requests/D1QueryRequest.php | 2 +- src/L1ServiceProvider.php | 2 -- 7 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/CloudflareRequest.php b/src/CloudflareRequest.php index d530e22..59abafe 100644 --- a/src/CloudflareRequest.php +++ b/src/CloudflareRequest.php @@ -2,8 +2,8 @@ namespace RenokiCo\L1; -use Saloon\Http\Request; use Saloon\Contracts\Connector; +use Saloon\Http\Request; abstract class CloudflareRequest extends Request { diff --git a/src/D1/D1Connection.php b/src/D1/D1Connection.php index e9b2214..fb0aff1 100644 --- a/src/D1/D1Connection.php +++ b/src/D1/D1Connection.php @@ -3,8 +3,8 @@ namespace RenokiCo\L1\D1; use Illuminate\Database\SQLiteConnection; -use RenokiCo\L1\D1\Pdo\D1Pdo; use RenokiCo\L1\CloudflareD1Connector; +use RenokiCo\L1\D1\Pdo\D1Pdo; class D1Connection extends SQLiteConnection { diff --git a/src/D1/D1SchemaGrammar.php b/src/D1/D1SchemaGrammar.php index 4b54b14..967f1d7 100644 --- a/src/D1/D1SchemaGrammar.php +++ b/src/D1/D1SchemaGrammar.php @@ -2,8 +2,8 @@ namespace RenokiCo\L1\D1; -use Illuminate\Support\Str; use Illuminate\Database\Schema\Grammars\SQLiteGrammar; +use Illuminate\Support\Str; class D1SchemaGrammar extends SQLiteGrammar { diff --git a/src/D1/Pdo/D1Pdo.php b/src/D1/Pdo/D1Pdo.php index 62f958a..bdf6c4b 100644 --- a/src/D1/Pdo/D1Pdo.php +++ b/src/D1/Pdo/D1Pdo.php @@ -4,7 +4,6 @@ use PDO; use PDOStatement; -use RenokiCo\L1\D1\Pdo\D1PdoStatement; use RenokiCo\L1\CloudflareD1Connector; class D1Pdo extends PDO diff --git a/src/D1/Pdo/D1PdoStatement.php b/src/D1/Pdo/D1PdoStatement.php index 2e7683e..1c7e13b 100644 --- a/src/D1/Pdo/D1PdoStatement.php +++ b/src/D1/Pdo/D1PdoStatement.php @@ -13,7 +13,6 @@ class D1PdoStatement extends PDOStatement protected array $bindings = []; protected array $responses = []; - public function __construct( protected D1Pdo &$pdo, protected string $query, @@ -51,7 +50,7 @@ public function execute($params = []): bool $this->bindings, ); - if ($response->failed() || !$response->json('success')) { + if ($response->failed() || ! $response->json('success')) { throw new PDOException( (string) $response->json('errors.0.message'), (int) $response->json('errors.0.code'), diff --git a/src/D1/Requests/D1QueryRequest.php b/src/D1/Requests/D1QueryRequest.php index 6becdb9..c43178d 100644 --- a/src/D1/Requests/D1QueryRequest.php +++ b/src/D1/Requests/D1QueryRequest.php @@ -2,9 +2,9 @@ namespace RenokiCo\L1\D1\Requests; -use Saloon\Enums\Method; use RenokiCo\L1\CloudflareRequest; use Saloon\Contracts\Body\HasBody; +use Saloon\Enums\Method; use Saloon\Traits\Body\HasJsonBody; class D1QueryRequest extends CloudflareRequest implements HasBody diff --git a/src/L1ServiceProvider.php b/src/L1ServiceProvider.php index cd26406..03a7037 100644 --- a/src/L1ServiceProvider.php +++ b/src/L1ServiceProvider.php @@ -2,9 +2,7 @@ namespace RenokiCo\L1; -use Illuminate\Support\Facades\DB; use Illuminate\Support\ServiceProvider; -use RenokiCo\L1\CloudflareD1Connector; use RenokiCo\L1\D1\D1Connection; class L1ServiceProvider extends ServiceProvider