mirror of
https://github.com/HMCL-dev/HMCL.git
synced 2025-03-07 17:36:52 +08:00
Add response text to exception message when authlib-injector meta is malformed
This commit is contained in:
parent
ea5b31d537
commit
8cdab4710b
@ -175,10 +175,11 @@ public class AuthlibInjectorServer implements Observable {
|
||||
|
||||
private void refreshMetadata(byte[] rawResponse) throws IOException {
|
||||
long timestamp = System.currentTimeMillis();
|
||||
String text = new String(rawResponse, UTF_8);
|
||||
try {
|
||||
setMetadataResponse(new String(rawResponse, UTF_8), timestamp);
|
||||
setMetadataResponse(text, timestamp);
|
||||
} catch (JsonParseException e) {
|
||||
throw new IOException("Malformed response", e);
|
||||
throw new IOException("Malformed response\n" + text, e);
|
||||
}
|
||||
|
||||
metadataRefreshed = true;
|
||||
|
Loading…
Reference in New Issue
Block a user