Skip to content

Commit

Permalink
StandardCharsets => common Charset objects
Browse files Browse the repository at this point in the history
  • Loading branch information
pasquy73 committed Nov 11, 2024
1 parent 356177a commit af648e8
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package it.eng.dome.billing.proxy.utils;

import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.util.Properties;

import lombok.NonNull;
Expand Down Expand Up @@ -35,7 +36,7 @@ public Call createPostRequest(@NonNull String baseUrl, @NonNull String path,
.url(urlBuilder.build().toString())
.header(USER_AGENT_NAME, USER_AGENT_VALUE)
.addHeader(CONTENT_TYPE, JSON.toString())
.post(RequestBody.create(body.getBytes(Charset.forName("UTF-8")), JSON))
.post(RequestBody.create(body.getBytes(StandardCharsets.UTF_8), JSON))
.build();

// Creates the call
Expand Down

0 comments on commit af648e8

Please sign in to comment.