mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-10 19:51:00 +00:00
[improvement] supersonic adapt checkstyle (#451)
This commit is contained in:
@@ -29,7 +29,6 @@ public abstract class AuthenticationInterceptor implements HandlerInterceptor {
|
||||
|
||||
protected S2ThreadContext s2ThreadContext;
|
||||
|
||||
|
||||
protected boolean isExcludedUri(String uri) {
|
||||
String excludePathStr = authenticationConfig.getExcludePath();
|
||||
if (Strings.isEmpty(excludePathStr)) {
|
||||
@@ -59,7 +58,6 @@ public abstract class AuthenticationInterceptor implements HandlerInterceptor {
|
||||
return "true".equalsIgnoreCase(internal);
|
||||
}
|
||||
|
||||
|
||||
protected void reflectSetparam(HttpServletRequest request, String key, String value) {
|
||||
try {
|
||||
if (request instanceof StandardMultipartHttpServletRequest) {
|
||||
|
||||
@@ -76,5 +76,4 @@ public class DefaultAuthenticationInterceptor extends AuthenticationInterceptor
|
||||
s2ThreadContext.set(threadContext);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -20,7 +20,6 @@ public class UserRepositoryImpl implements UserRepository {
|
||||
this.userDOMapper = userDOMapper;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public List<UserDO> getUserList() {
|
||||
return userDOMapper.selectByExample(new UserDOExample());
|
||||
@@ -40,5 +39,4 @@ public class UserRepositoryImpl implements UserRepository {
|
||||
return userDOOptional.orElse(null);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -29,7 +29,6 @@ public class UserController {
|
||||
this.userService = userService;
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("/getCurrentUser")
|
||||
public User getCurrentUser(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) {
|
||||
return UserHolder.findUser(httpServletRequest, httpServletResponse);
|
||||
@@ -70,5 +69,4 @@ public class UserController {
|
||||
return userService.login(userCmd);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -13,7 +13,6 @@ import org.springframework.stereotype.Service;
|
||||
@Service
|
||||
public class UserServiceImpl implements UserService {
|
||||
|
||||
|
||||
@Override
|
||||
public List<String> getUserNames() {
|
||||
return ComponentFactory.getUserAdaptor().getUserNames();
|
||||
|
||||
@@ -20,5 +20,4 @@ public class FakeUserStrategy implements UserStrategy {
|
||||
return User.getFakeUser();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -58,7 +58,6 @@ public class UserTokenUtils {
|
||||
return generate(claims);
|
||||
}
|
||||
|
||||
|
||||
public User getUser(HttpServletRequest request) {
|
||||
String token = request.getHeader(authenticationConfig.getTokenHttpHeaderKey());
|
||||
final Claims claims = getClaims(token);
|
||||
@@ -120,5 +119,4 @@ public class UserTokenUtils {
|
||||
.compact();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -75,7 +75,6 @@ public class AuthServiceImpl implements AuthService {
|
||||
jdbcTemplate.update("delete from s2_auth_groups where group_id = ?", group.getGroupId());
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public AuthorizedResourceResp queryAuthorizedResources(QueryAuthResReq req, User user) {
|
||||
Set<String> userOrgIds = userService.getUserAllOrgId(user.getName());
|
||||
|
||||
Reference in New Issue
Block a user