<BUG>buffer.append(((WebRequest)request).getServletPath());}</BUG><CONTEXT>final WebRequest request = cycle.getWebRequest();if (request != null){final String contextPath = request.getContextPath();buffer.append(contextPath);<extra_id_0>return buffer;}</CONTEXT>
String path = ((WebRequest)request).getServletPath();if(path == null || "".equals(path)) path = "/";buffer.append(path);