logger = $logger ?: new NullLogger(); } public static function getRouteDef(array $prevMiddleware = [], array $postMiddleware = []): array { return [ 'name' => static::class, 'middleware' => \array_merge($prevMiddleware, [static::class], $postMiddleware), 'path' => static::ROUTE_PATH, 'allowed_methods' => static::ALLOWED_METHODS, ]; } }