Skip to content

Commit

Permalink
Change some parameter names
Browse files Browse the repository at this point in the history
  • Loading branch information
msavy committed Feb 4, 2017
1 parent 56c206f commit a8ff82e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Expand Up @@ -22,7 +22,7 @@
* @author Marc Savy {@literal <marc@rhymewithgravy.com>}
*/
public enum AuthType {
NONE(new NoneAuth()), BASIC(new BasicAuth()), OAUTH2(new OAuth2ClientCredentials());
NONE(new NoneAuth()), BASIC(new BasicAuth()), OAUTH2CLIENTCREDENTIALS(new OAuth2ClientCredentials());

private Authenticator auth;

Expand Down
Expand Up @@ -42,7 +42,7 @@ public OAuth2ClientCredentials() {
public Authenticator validateConfig(Map<String, String> config) {
Objects.requireNonNull(config.get("clientId"), "must provide clientId");
Objects.requireNonNull(config.get("clientSecret"), "must provide clientSecret");
Objects.requireNonNull(config.get("uri"), "must provide OAuth URI 'uri'.");
Objects.requireNonNull(config.get("oauthUri"), "must provide OAuth URI 'uri'.");
return this;
}

Expand All @@ -51,7 +51,7 @@ public Authenticator authenticate(Vertx vertx, Map<String, String> config, Multi
OAuth2ClientOptions credentials = new OAuth2ClientOptions()
.setClientID(config.get("clientId"))
.setClientSecret(config.get("clientSecret"))
.setSite(config.get("uri"));
.setSite(config.get("oauthUri"));

OAuth2Auth oauth2 = OAuth2Auth.create(vertx, OAuth2FlowType.CLIENT, credentials);

Expand Down

0 comments on commit a8ff82e

Please sign in to comment.