This commit is contained in:
Reinhard Pointner 2016-05-24 21:51:02 +08:00
parent 6bf68fea55
commit 9eb8d67007
1 changed files with 3 additions and 3 deletions

View File

@ -343,11 +343,11 @@ public final class WebRequest {
String log = String.format(Locale.ROOT, "Received %,d bytes", data.remaining()); String log = String.format(Locale.ROOT, "Received %,d bytes", data.remaining());
// log entire response content if enabled // log entire response content if enabled
SystemProperty<Boolean> response = SystemProperty.of("net.filebot.web.WebRequest.log.response", Boolean::parseBoolean, Boolean.FALSE); boolean printResponse = SystemProperty.of("net.filebot.web.WebRequest.log.response", Boolean::parseBoolean, Boolean.FALSE).get();
if (response.get()) {
if (printResponse) {
return log + System.lineSeparator() + UTF_8.decode(data.duplicate()) + System.lineSeparator(); return log + System.lineSeparator() + UTF_8.decode(data.duplicate()) + System.lineSeparator();
} }
return log; return log;
}; };