feat:实现动态响应处理

This commit is contained in:
wangyu 2022-01-26 10:30:38 +08:00
parent de7cf255b7
commit 975526b811

View File

@ -24,8 +24,7 @@ public class ReactiveUserAuditor implements ReactiveAuditorAware<String> {
@NonNull
public Mono<String> getCurrentAuditor() {
return ReactiveSecurityContextHolder.getContext()
.map(UserUtils::extractUserName)
.defaultIfEmpty("匿名用户");
.map(UserUtils::extractUserName);
}
}