eganwu 2 лет назад
Родитель
Сommit
e90ec233e7
1 измененных файлов с 5 добавлено и 8 удалено
  1. 5 8
      src/custom/restcontroller/common/usercenter/usercenter.java

+ 5 - 8
src/custom/restcontroller/common/usercenter/usercenter.java

@@ -328,7 +328,7 @@ public class usercenter extends Controller {
             }
 
             Rows unionidsRows = dbConnect.runSqlQuery("select * from sys_wechatapp_unionids where userid='" + userid + "'");
-            if ( unionidsRows.isNotEmpty()) {
+            if (unionidsRows.isNotEmpty()) {
                 if (!unionidsRows.get(0).getString("unionid").equals(unionid)) {
                     return getErrReturnObject().setErrMsg("当前账号已绑定微信,如需绑定其他微信,请先进行解绑操作!").toJSONString();
                 }
@@ -387,7 +387,6 @@ public class usercenter extends Controller {
             updateSQL.setValue("userid", userid);
             updateSQL.update();
             if (usertype == 99) {
-
                 new StoreHelper().updateUserType22(this);
             }
 
@@ -403,12 +402,10 @@ public class usercenter extends Controller {
                 new StoreHelper().updateUserType99(this);
             }
         }
-        if (sqllist.size() > 0) {
-            dbConnect.runSqlUpdate(sqllist);
-            return getSucReturnObject().toString();
-        } else {
-            return getErrReturnObject().toString();
-        }
+
+        dbConnect.runSqlUpdate(sqllist);
+        return getSucReturnObject().toString();
+
     }
 
     @API(title = "微信公众号绑定", accesstoken = false)