zhongjiajie commented on code in PR #11255:
URL: https://github.com/apache/dolphinscheduler/pull/11255#discussion_r944056000


##########
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/impl/UsersServiceImpl.java:
##########
@@ -406,8 +392,7 @@ public Map<String, Object> updateUser(User loginUser, int 
userId,
             throw new ServiceException(Status.USER_NOT_EXIST.getMsg());
         }
 
-        checkUserParams(userPassword, email, phone, state);
-
+        checkUserParams(userName, userPassword, email, phone);

Review Comment:
   > Due to `check params` are used by both `createUser` and `updateUser` (one 
of which requires that `userName` does not exist and one of which requires that 
it must exist), `check params` cannot take `userName` as an argument and should 
be handled by each function.
   
   I look at the code, and your comment above it true. but when I check the 
income form from the frontend, it will always pass the username when it tries 
to update the user, so I think we can check `username` in both create or update 
user, WDYT?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to