From fc6a899f16655c8824b896e14b626b856e9234a7 Mon Sep 17 00:00:00 2001 From: flashwave Date: Sat, 5 Oct 2024 15:28:56 +0000 Subject: [PATCH] Fixed some URLs not getting registered properly. --- src/LegacyRoutes.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/LegacyRoutes.php b/src/LegacyRoutes.php index 2e5cf1a..fc80267 100644 --- a/src/LegacyRoutes.php +++ b/src/LegacyRoutes.php @@ -2,16 +2,18 @@ namespace Misuzu; use Index\Http\Routing\{HttpGet,RouteHandler,RouteHandlerTrait}; -use Index\Urls\{UrlFormat,UrlRegistry,UrlSource,UrlSourceTrait}; +use Index\Urls\{UrlFormat,UrlRegistry,UrlSource}; class LegacyRoutes implements RouteHandler, UrlSource { - use RouteHandlerTrait, UrlSourceTrait; + use RouteHandlerTrait; public function __construct( private UrlRegistry $urls ) {} public function registerUrls(UrlRegistry $urls): void { + UrlFormat::register($urls, $this); + // eventually this should be handled by context classes $urls->register('search-index', '/search.php'); $urls->register('search-query', '/search.php', ['q' => ''], '
');