specify utf8 encoding
this should fix the following known bugs: - putting a U+2019 in the config causes it to become corrupted and ~double in size every launch - scripts become assembled incorrectly and the nbsp after your name in the chatbox becomes incorrect - the feed panel doesn't show emoji
This commit is contained in:
@@ -28,6 +28,7 @@ import com.google.gson.JsonParseException;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.InputStreamReader;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import net.runelite.http.api.RuneLiteAPI;
|
||||
@@ -63,7 +64,7 @@ public class FeedClient
|
||||
}
|
||||
|
||||
InputStream in = response.body().byteStream();
|
||||
return RuneLiteAPI.GSON.fromJson(new InputStreamReader(in), FeedResult.class);
|
||||
return RuneLiteAPI.GSON.fromJson(new InputStreamReader(in, StandardCharsets.UTF_8), FeedResult.class);
|
||||
}
|
||||
catch (JsonParseException ex)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user