From c225eef933c195941f65985b7364a27f119aa7d0 Mon Sep 17 00:00:00 2001 From: korridor <26689068+korridor@users.noreply.github.com> Date: Wed, 18 Sep 2019 23:06:23 +0200 Subject: [PATCH] Added code formatting diff from style ci --- resources/lang/de/validation.php | 2 +- resources/lang/en/validation.php | 2 +- src/Rules/ExistsEloquent.php | 4 ++-- src/Rules/UniqueEloquent.php | 6 +++--- tests/Feature/ExistsEloquentTest.php | 6 +++--- tests/Feature/UniqueEloquentTest.php | 6 +++--- tests/TestCase.php | 6 +++--- tests/TestEnvironment/Models/Fact.php | 2 +- tests/TestEnvironment/Models/User.php | 2 +- 9 files changed, 18 insertions(+), 18 deletions(-) diff --git a/resources/lang/de/validation.php b/resources/lang/de/validation.php index 51da175..51581e0 100644 --- a/resources/lang/de/validation.php +++ b/resources/lang/de/validation.php @@ -2,5 +2,5 @@ return [ 'exists_model' => 'Die Ressource existiert nicht.', - 'unique_model' => 'Die Ressource existiert bereits.', + 'unique_model' => 'Die Ressource existiert bereits.', ]; diff --git a/resources/lang/en/validation.php b/resources/lang/en/validation.php index 9781d41..58b0526 100644 --- a/resources/lang/en/validation.php +++ b/resources/lang/en/validation.php @@ -2,5 +2,5 @@ return [ 'exists_model' => 'The resource does not exist.', - 'unique_model' => 'The resource already exists.', + 'unique_model' => 'The resource already exists.', ]; diff --git a/src/Rules/ExistsEloquent.php b/src/Rules/ExistsEloquent.php index 781b313..72f1832 100644 --- a/src/Rules/ExistsEloquent.php +++ b/src/Rules/ExistsEloquent.php @@ -3,8 +3,8 @@ namespace Korridor\LaravelModelValidationRules\Rules; use Closure; -use Illuminate\Contracts\Validation\Rule; use Illuminate\Database\Eloquent\Model; +use Illuminate\Contracts\Validation\Rule; class ExistsEloquent implements Rule { @@ -99,7 +99,7 @@ public function setBuilderClosure(?Closure $builderClosure) * @param Closure $builderClosure * @return $this */ - public function query(Closure $builderClosure): ExistsEloquent + public function query(Closure $builderClosure): self { $this->setBuilderClosure($builderClosure); diff --git a/src/Rules/UniqueEloquent.php b/src/Rules/UniqueEloquent.php index af88b8d..a1a466d 100644 --- a/src/Rules/UniqueEloquent.php +++ b/src/Rules/UniqueEloquent.php @@ -3,8 +3,8 @@ namespace Korridor\LaravelModelValidationRules\Rules; use Closure; -use Illuminate\Contracts\Validation\Rule; use Illuminate\Database\Eloquent\Model; +use Illuminate\Contracts\Validation\Rule; class UniqueEloquent implements Rule { @@ -110,7 +110,7 @@ public function setBuilderClosure(?Closure $builderClosure): void * @param Closure $builderClosure * @return $this */ - public function query(Closure $builderClosure): UniqueEloquent + public function query(Closure $builderClosure): self { $this->setBuilderClosure($builderClosure); @@ -132,7 +132,7 @@ public function setIgnore($id, ?string $column = null): void * @param string|null $column * @return UniqueEloquent */ - public function ignore($id, ?string $column = null): UniqueEloquent + public function ignore($id, ?string $column = null): self { $this->setIgnore($id, $column); diff --git a/tests/Feature/ExistsEloquentTest.php b/tests/Feature/ExistsEloquentTest.php index 00bdbf9..131343c 100644 --- a/tests/Feature/ExistsEloquentTest.php +++ b/tests/Feature/ExistsEloquentTest.php @@ -2,12 +2,12 @@ namespace Korridor\LaravelModelValidationRules\Tests\Feature; +use Illuminate\Support\Str; +use Illuminate\Support\Facades\Lang; use Illuminate\Database\Eloquent\Builder; use Illuminate\Foundation\Testing\RefreshDatabase; -use Illuminate\Support\Facades\Lang; -use Illuminate\Support\Str; -use Korridor\LaravelModelValidationRules\Rules\ExistsEloquent; use Korridor\LaravelModelValidationRules\Tests\TestCase; +use Korridor\LaravelModelValidationRules\Rules\ExistsEloquent; use Korridor\LaravelModelValidationRules\Tests\TestEnvironment\Models\Fact; use Korridor\LaravelModelValidationRules\Tests\TestEnvironment\Models\User; diff --git a/tests/Feature/UniqueEloquentTest.php b/tests/Feature/UniqueEloquentTest.php index 7dd2628..880704f 100644 --- a/tests/Feature/UniqueEloquentTest.php +++ b/tests/Feature/UniqueEloquentTest.php @@ -2,12 +2,12 @@ namespace Korridor\LaravelModelValidationRules\Tests\Feature; +use Illuminate\Support\Str; +use Illuminate\Support\Facades\Lang; use Illuminate\Database\Eloquent\Builder; use Illuminate\Foundation\Testing\RefreshDatabase; -use Illuminate\Support\Facades\Lang; -use Illuminate\Support\Str; -use Korridor\LaravelModelValidationRules\Rules\UniqueEloquent; use Korridor\LaravelModelValidationRules\Tests\TestCase; +use Korridor\LaravelModelValidationRules\Rules\UniqueEloquent; use Korridor\LaravelModelValidationRules\Tests\TestEnvironment\Models\Fact; use Korridor\LaravelModelValidationRules\Tests\TestEnvironment\Models\User; diff --git a/tests/TestCase.php b/tests/TestCase.php index 2e94eba..70dd940 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -2,13 +2,13 @@ namespace Korridor\LaravelModelValidationRules\Tests; +use Illuminate\Events\Dispatcher; use Illuminate\Container\Container; use Illuminate\Database\Capsule\Manager; -use Illuminate\Database\Eloquent\Factory as EloquentFactory; use Illuminate\Database\Schema\Blueprint; -use Illuminate\Events\Dispatcher; -use Korridor\LaravelModelValidationRules\ModelValidationServiceProvider; use Orchestra\Testbench\TestCase as Orchestra; +use Illuminate\Database\Eloquent\Factory as EloquentFactory; +use Korridor\LaravelModelValidationRules\ModelValidationServiceProvider; abstract class TestCase extends Orchestra { diff --git a/tests/TestEnvironment/Models/Fact.php b/tests/TestEnvironment/Models/Fact.php index 6c0776f..5e3158e 100644 --- a/tests/TestEnvironment/Models/Fact.php +++ b/tests/TestEnvironment/Models/Fact.php @@ -3,8 +3,8 @@ namespace Korridor\LaravelModelValidationRules\Tests\TestEnvironment\Models; use Illuminate\Database\Eloquent\Model; -use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\SoftDeletes; +use Illuminate\Database\Eloquent\Relations\BelongsTo; class Fact extends Model { diff --git a/tests/TestEnvironment/Models/User.php b/tests/TestEnvironment/Models/User.php index 684fc08..85da702 100644 --- a/tests/TestEnvironment/Models/User.php +++ b/tests/TestEnvironment/Models/User.php @@ -3,8 +3,8 @@ namespace Korridor\LaravelModelValidationRules\Tests\TestEnvironment\Models; use Illuminate\Database\Eloquent\Model; -use Illuminate\Database\Eloquent\Relations\HasMany; use Illuminate\Database\Eloquent\SoftDeletes; +use Illuminate\Database\Eloquent\Relations\HasMany; class User extends Model {