Skip to content
This repository has been archived by the owner on Sep 26, 2019. It is now read-only.

Commit

Permalink
Update Enclave executePost method (#1317)
Browse files Browse the repository at this point in the history
Use class field rather than creating new instance for each call.
  • Loading branch information
AbdelStark authored and lucassaldanha committed Apr 23, 2019
1 parent 9f3a56d commit 9aa9c7c
Showing 1 changed file with 0 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,6 @@ private Request buildPostRequest(
}

private <T> T executePost(final Request request, final Class<T> responseType) throws IOException {
OkHttpClient client = new OkHttpClient();

try (Response response = client.newCall(request).execute()) {
return objectMapper.readValue(response.body().string(), responseType);
} catch (IOException e) {
Expand Down

0 comments on commit 9aa9c7c

Please sign in to comment.