We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c29f019 commit 40d87d7Copy full SHA for 40d87d7
oauth2-server-core/src/main/java/nl/myndocs/oauth2/request/auth/BasicAuthenticator.kt
@@ -5,11 +5,9 @@ import nl.myndocs.oauth2.request.CallContext
5
import nl.myndocs.oauth2.request.headerCaseInsensitive
6
7
open class BasicAuthenticator(protected val context: CallContext) {
8
- fun extractCredentials(): Credentials? {
9
- val authorizationHeader = context.headerCaseInsensitive("authorization") ?: ""
10
-
11
- return BasicAuth.parseCredentials(authorizationHeader)
12
- }
+ fun extractCredentials() = BasicAuth.parseCredentials(
+ context.headerCaseInsensitive("authorization") ?: ""
+ )
13
14
fun openAuthenticationDialog() {
15
context.respondHeader("WWW-Authenticate", "Basic realm=\"${context.queryParameters["client_id"]}\"")
0 commit comments