has(StateKey::ROUTE_CONTEXT)) { error_log("ControllerRequestMiddleware: No ROUTE_CONTEXT found, skipping controller invocation"); return $next($context); } $routeContext = $stateManager->get(StateKey::ROUTE_CONTEXT); error_log("ControllerRequestMiddleware: Route context found, invoking controller"); // TODO: Implement proper controller invocation // For now, just pass through error_log("ControllerRequestMiddleware: Controller invocation not yet implemented"); return $next($context); } }