|
1 | 1 | /* |
2 | | - * Copyright 2002-2020 the original author or authors. |
| 2 | + * Copyright 2002-2021 the original author or authors. |
3 | 3 | * |
4 | 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
5 | 5 | * you may not use this file except in compliance with the License. |
|
29 | 29 | import java.util.function.Supplier; |
30 | 30 | import java.util.stream.Collectors; |
31 | 31 |
|
32 | | -import com.nimbusds.oauth2.sdk.util.StringUtils; |
33 | 32 | import reactor.core.publisher.Mono; |
34 | 33 |
|
35 | 34 | import org.springframework.context.ApplicationContext; |
|
82 | 81 | import org.springframework.test.web.reactive.server.WebTestClientConfigurer; |
83 | 82 | import org.springframework.util.Assert; |
84 | 83 | import org.springframework.util.ClassUtils; |
| 84 | +import org.springframework.util.StringUtils; |
85 | 85 | import org.springframework.web.reactive.result.method.HandlerMethodArgumentResolver; |
86 | 86 | import org.springframework.web.reactive.result.method.annotation.ArgumentResolverConfigurer; |
87 | 87 | import org.springframework.web.reactive.result.method.annotation.RequestMappingHandlerAdapter; |
@@ -663,7 +663,7 @@ private Collection<GrantedAuthority> defaultAuthorities() { |
663 | 663 | return getAuthorities((Collection) scope); |
664 | 664 | } |
665 | 665 | String scopes = scope.toString(); |
666 | | - if (StringUtils.isBlank(scopes)) { |
| 666 | + if (!StringUtils.hasText(scopes)) { |
667 | 667 | return Collections.emptyList(); |
668 | 668 | } |
669 | 669 | return getAuthorities(Arrays.asList(scopes.split(" "))); |
|
0 commit comments