Skip to content

Commit

Permalink
[feature/validation-wrapping] Rename ValidationHandler and update ref…
Browse files Browse the repository at this point in the history
…erences

Moved the ValidationHandler class to the Validation namespace and updated all relevant references in tests and documentation. This refactor improves the project structure by grouping validation-related code logically.
  • Loading branch information
midnite81 committed Sep 4, 2024
1 parent d0cc63c commit 9e66351
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions docs/Handlers/ValidationHandler.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ composer require midnite81/core
### Basic Usage

```php
use Midnite81\Core\Handlers\ValidationHandler;
use Midnite81\Core\Validation\ValidationHandler;

$handler = ValidationHandler::make()
->setRules([
Expand All @@ -58,7 +58,7 @@ classes:

```php
use App\Http\Requests\YourCustomFormRequest;
use Midnite81\Core\Handlers\ValidationHandler;
use Midnite81\Core\Validation\ValidationHandler;

$handler = ValidationHandler::make()
->setFormRequest(YourCustomFormRequest::class)
Expand Down Expand Up @@ -129,7 +129,7 @@ Here's a comprehensive example of how you might use the `ValidationHandler` in a
nature of the `onFail` callback:

```php
use Midnite81\Core\Handlers\ValidationHandler;
use Midnite81\Core\Validation\ValidationHandler;
use Illuminate\Validation\ValidationException;

class YourController extends Controller
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Midnite81\Core\Handlers;
namespace Midnite81\Core\Validation;

use Closure;
use Illuminate\Auth\Access\AuthorizationException;
Expand Down
2 changes: 1 addition & 1 deletion tests/Handlers/ValidationHandlerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Route;
use Illuminate\Validation\ValidationException;
use Midnite81\Core\Handlers\ValidationHandler;
use Midnite81\Core\Tests\CoreTestCase;
use Midnite81\Core\Validation\ValidationHandler;

uses(CoreTestCase::class, WithoutMiddleware::class);

Expand Down

0 comments on commit 9e66351

Please sign in to comment.