mirror of
https://gh.wpcy.net/https://github.com/aspirepress/AspireCloud.git
synced 2026-07-17 11:37:03 +08:00
* feat: add description column/property to Theme * chore: add fulltext index to themes and plugins description columns * fix: serialize all fields of ThemeResource properly * feat: add NormalizeWpOrgRequest middleware * refactor: break ThemeController up into services * Implement hot tags theme info endpoint --------- Co-authored-by: Matthew Zalewski <matthew@minion.co.nz>
19 lines
453 B
PHP
19 lines
453 B
PHP
<?php
|
|
|
|
namespace App\Http\Middleware;
|
|
|
|
use Closure;
|
|
use Illuminate\Http\Request;
|
|
use Symfony\Component\HttpFoundation\Response;
|
|
|
|
class NormalizeWpOrgRequest
|
|
{
|
|
public function handle(Request $request, Closure $next): Response
|
|
{
|
|
if (is_array($rq = $request->query('request'))) {
|
|
// flatten 'request' query args into the top-level of the query
|
|
$request->merge($rq);
|
|
}
|
|
return $next($request);
|
|
}
|
|
}
|