private function needPrettyHandler() { $isHtmlResponse = ResponseTypeResolve::resolve() == "text/html"; return $isHtmlResponse && !Uri::isAjax(); }