Skip to content

Commit

Permalink
Change field username to user following documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
passtech authored Sep 1, 2022
1 parent 0906b8a commit 8660139
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -119,13 +119,13 @@ private void login() throws IOException {
HttpResponse<JsonNode> loginResult;

try {
loginResult = Unirest.post(serverUrl + "v1/login").field("username", user).field("password", password).asJson();
loginResult = Unirest.post(serverUrl + "v1/login").field("user", user).field("password", password).asJson();
} catch (UnirestException e) {
throw new IOException(e);
}

if (loginResult.getStatus() == 401)
throw new IOException("The username and password provided are incorrect.");
throw new IOException("The user and password provided are incorrect.");


if (loginResult.getStatus() != 200)
Expand Down

0 comments on commit 8660139

Please sign in to comment.