aboutsummaryrefslogtreecommitdiff
path: root/src/main/scala/google/OAuth2.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/scala/google/OAuth2.scala')
-rw-r--r--src/main/scala/google/OAuth2.scala8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/scala/google/OAuth2.scala b/src/main/scala/google/OAuth2.scala
index d17ec78..ff010ef 100644
--- a/src/main/scala/google/OAuth2.scala
+++ b/src/main/scala/google/OAuth2.scala
@@ -29,7 +29,7 @@ object OAuth2 {
/** Request a new access token for the given scopes.
*
- * Implements the OAUTH2 workflow as descried here
+ * Implements the OAUTH2 workflow as descried in
* https://developers.google.com/identity/protocols/OAuth2ServiceAccount
*/
def requestAccessToken(
@@ -89,18 +89,18 @@ object OAuth2 {
http.system.log.info("tracing access token expired, refreshing")
requestAccessToken(http, serviceAccountFile, scopes).map {
case (newExpiration, newToken) =>
- http.system.log.debug("new tracing access token otained")
+ http.system.log.debug("new tracing access token obtained")
(request, newExpiration, newToken)
}
} else {
Future.successful((request, expiration, accessToken))
}
}
- .drop(1) // drop initial element
+ .drop(1) // drop initial, empty HttpRequest
.map {
case (request, _, accessToken) =>
request.withHeaders(
- RawHeader("Authorization", "Bearer " + accessToken)
+ RawHeader("Authorization", s"Bearer $accessToken")
)
}