Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
peter-mw committed Aug 11, 2022
1 parent bad0470 commit 60eef74
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/MicroweberPackages/App/Http/Middleware/XSS.php
Expand Up @@ -14,7 +14,8 @@ public function handle(Request $request, Closure $next)
$input = $request->all();


if ($request->isMethod('post') and !empty($input)) {
if (($request->isMethod('post') or $request->isMethod('patch')) and !empty($input)) {

$clean = new HTMLClean();
array_walk_recursive($input, function (&$input) use ($clean) {
if (is_string($input)) {
Expand All @@ -23,7 +24,6 @@ public function handle(Request $request, Closure $next)
});
}


$request->merge($input);
return $next($request);
}
Expand Down

0 comments on commit 60eef74

Please sign in to comment.