Commit d8e3f581 authored by Liang Ding's avatar Liang Ding

🐛 Fix #12619

parent 17fbc135
...@@ -39,15 +39,12 @@ import org.b3log.solo.util.Solos; ...@@ -39,15 +39,12 @@ import org.b3log.solo.util.Solos;
import org.json.JSONArray; import org.json.JSONArray;
import org.json.JSONObject; import org.json.JSONObject;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
/** /**
* User console request processing. * User console request processing.
* *
* @author <a href="http://88250.b3log.org">Liang Ding</a> * @author <a href="http://88250.b3log.org">Liang Ding</a>
* @author <a href="mailto:385321165@qq.com">DASHU</a> * @author <a href="mailto:385321165@qq.com">DASHU</a>
* @version 1.2.1.4, Dec 11, 2018 * @version 1.2.1.5, Jan 10, 2019
* @since 0.4.0 * @since 0.4.0
*/ */
@RequestProcessor @RequestProcessor
...@@ -162,7 +159,6 @@ public class UserConsole { ...@@ -162,7 +159,6 @@ public class UserConsole {
* *
* @param context the specified http request context * @param context the specified http request context
*/ */
@Before(ConsoleAdminAuthAdvice.class)
public void addUser(final RequestContext context) { public void addUser(final RequestContext context) {
final JsonRenderer renderer = new JsonRenderer(); final JsonRenderer renderer = new JsonRenderer();
context.setRenderer(renderer); context.setRenderer(renderer);
...@@ -170,8 +166,6 @@ public class UserConsole { ...@@ -170,8 +166,6 @@ public class UserConsole {
renderer.setJSONObject(ret); renderer.setJSONObject(ret);
try { try {
final HttpServletRequest request = context.getRequest();
final HttpServletResponse response = context.getResponse();
final JSONObject requestJSONObject = context.requestJSON(); final JSONObject requestJSONObject = context.requestJSON();
if (Solos.isAdminLoggedIn(context)) { // if the administrator register a new user, treats the new user as a normal user if (Solos.isAdminLoggedIn(context)) { // if the administrator register a new user, treats the new user as a normal user
// (defaultRole) who could post article // (defaultRole) who could post article
......
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