[Users | Trunk]: Remove encoding from create params
This commit is contained in:
parent
6665403c55
commit
6e1d2cb6b8
|
@ -11,6 +11,7 @@ import org.springframework.stereotype.Component;
|
|||
import org.springframework.web.client.RestTemplate;
|
||||
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.net.URLDecoder;
|
||||
import java.net.URLEncoder;
|
||||
import java.nio.charset.Charset;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
|
@ -86,12 +87,7 @@ public class HttpUtils {
|
|||
int count = 0;
|
||||
for (Map.Entry<String, String> param : params.entrySet()) {
|
||||
ret.append(param.getKey()).append("=");
|
||||
try {
|
||||
ret.append(URLEncoder.encode(param.getValue(), StandardCharsets.UTF_8.toString()));
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
logger.error("UnsupportedEncodingException on param " + param);
|
||||
return null;
|
||||
}
|
||||
ret.append(param.getValue());
|
||||
count++;
|
||||
if (count != params.entrySet().size()) {
|
||||
ret.append("&");
|
||||
|
|
Loading…
Reference in New Issue