Skip to content

Commit 655145d

Browse files
committed
fix filters namespace
1 parent 76fb861 commit 655145d

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

lib/Endpoint/Filters/Authorize.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* @link https://github.com/DevNet-Framework
77
*/
88

9-
namespace DevNet\Web\Security\Authorization;
9+
namespace DevNet\Web\Endpoint\Filters;
1010

1111
use DevNet\System\Async\Task;
1212
use DevNet\Web\Endpoint\ActionContext;

lib/Endpoint/Filters/ValidateAntiForgery.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* @link https://github.com/DevNet-Framework
77
*/
88

9-
namespace DevNet\Web\Security\Tokens\Csrf;
9+
namespace DevNet\Web\Endpoint\Filters;
1010

1111
use DevNet\System\Async\Task;
1212
use DevNet\Web\Endpoint\ActionContext;
@@ -21,12 +21,12 @@ class ValidateAntiForgery implements IActionFilter
2121
{
2222
public function __invoke(ActionContext $context, ActionDelegate $next): Task
2323
{
24-
$antiforgery = $context->HttpContext->Services->getService(IAntiForgery::class);
25-
if (!$antiforgery) {
24+
$antiForgery = $context->HttpContext->Services->getService(IAntiForgery::class);
25+
if (!$antiForgery) {
2626
throw new AntiForgeryException("Unable to get IAntiForgery service, make sure to register it as a service!");
2727
}
2828

29-
$result = $antiforgery->validateToken($context->HttpContext);
29+
$result = $antiForgery->validateToken($context->HttpContext);
3030

3131
if (!$result) {
3232
throw new AntiForgeryException("Invalid AntiForgery Token!", 403);

0 commit comments

Comments
 (0)