Commit 49f746ab authored by yanzg's avatar yanzg

异常处理显示

parent d631d43c
......@@ -62,17 +62,21 @@ public class CookiesHelper {
// 遍历cookies找到对应的Cookies
for (Cookie item : request.getCookies()) {
if (item.getName().equals(key)) {
removeCookie(response, item.getName());
if (StringHelper.isNumber(item.getValue())) {
keyLength = StringHelper.toInt(item.getValue());
String itemKey = item.getName();
String itemValue = item.getValue();
if (itemKey.equals(key)) {
removeCookie(response, itemKey);
if (StringHelper.isEmpty(itemValue)) {
return StringHelper.EMPTY;
} else if (StringHelper.isNumber(itemValue)) {
keyLength = StringHelper.toInt(itemValue);
continue;
} else {
return URLDecoder.decode(item.getValue(), CHARSET);
return URLDecoder.decode(itemValue, CHARSET);
}
} else if (item.getName().startsWith(key)) {
removeCookie(response, item.getName());
map.put(key, item.getValue());
} else if (itemKey.startsWith(key)) {
removeCookie(response, itemKey);
map.put(key, itemValue);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment