refactor(app): 优化APP 模块登录用户名不匹配的日志

This commit is contained in:
冷冷 committed 2024-11-25 14:12:24 +08:00
1 parent 476d829633
commit 3c42274dee
1 file changed
+1 -1
@@ -84,7 +84,7 @@ public class PigxTocDefaultUserDetailsServiceImpl implements PigxUserDetailsServ
UserDetails getUserDetailsAppUser(R<AppUserInfo> result) {
// @formatter:off
return RetOps.of(result)
.assertSuccess(r -> new OAuth2AuthenticationException(new OAuth2Error(OAuth2ErrorCodes.SERVER_ERROR, "用户信息获取失败",null)))
.assertSuccess(r -> new OAuth2AuthenticationException(new OAuth2Error(OAuth2ErrorCodes.SERVER_ERROR, "用户名或密码错误",null)))
.getData()
.map(this::convertUserDetailsAppUser)
.orElseThrow(() -> new UsernameNotFoundException("用户不存在"));