Skip to content
This repository has been archived by the owner on Nov 19, 2018. It is now read-only.

Don't use internal sun.misc.BASE64Encoder #45

Merged
merged 1 commit into from
Apr 6, 2016
Merged

Don't use internal sun.misc.BASE64Encoder #45

merged 1 commit into from
Apr 6, 2016

Conversation

almson
Copy link
Contributor

@almson almson commented Apr 5, 2016

Using sun.misc classes throws ugly compile warnings. The AWS SDK has its own base64 utility. Also, deleted unused imports.

The AWS SDK has its own base64 utility.
@@ -256,7 +253,7 @@ private String bytesToHex(byte[] bytes) {
private String base64EncodePolicy(JsonElement jsonElement) throws UnsupportedEncodingException
{
String policyJsonStr = jsonElement.toString();
String base64Encoded = (new BASE64Encoder()).encode(policyJsonStr.getBytes("UTF-8")).replaceAll("\n","").replaceAll("\r", "");
String base64Encoded = BinaryUtils.toBase64 (policyJsonStr.getBytes("UTF-8"));

This comment was marked as spam.

This comment was marked as spam.

@rnicholus rnicholus merged commit 7a65295 into FineUploader:master Apr 6, 2016
@rnicholus
Copy link
Member

Thanks for the codez!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants