Commit c33dbbe9 authored by Liang Ding's avatar Liang Ding

🎨 登出重定向

parent 9ea3e9c5
......@@ -191,13 +191,8 @@ public class IndexProcessor {
Solos.logout(httpServletRequest, context.getResponse());
String referer = context.header("referer");
if (StringUtils.isBlank(referer) || !isInternalLinks(referer)) {
referer = Latkes.getServePath();
}
Solos.addGoogleNoIndex(context);
context.sendRedirect(referer);
context.sendRedirect(Latkes.getServePath());
}
/**
......
......@@ -215,9 +215,9 @@ public class UserQueryService {
*/
public String getLogoutURL() {
String to = Latkes.getServePath();
to = URLs.encode(to + "/");
to = URLs.encode(to);
return Latkes.getContextPath() + "/logout?goto=" + to;
return Latkes.getContextPath() + "/logout?referer=" + to;
}
/**
......@@ -230,6 +230,6 @@ public class UserQueryService {
String to = Latkes.getServePath();
to = URLs.encode(to + redirectURL);
return Latkes.getContextPath() + "/start?goto=" + to;
return Latkes.getContextPath() + "/start?referer=" + to;
}
}
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