[#979] Moved '../' '../../' replacement

This fixes issue where exported player pages' js and css links are one
level too high
This commit is contained in:
Rsl1122 2019-04-02 17:44:02 +03:00
parent 8928ded103
commit 0ff83713ec

View File

@ -91,7 +91,7 @@ public abstract class SpecificExport {
}
protected void exportPlayerPage(String playerName, String html) throws IOException {
List<String> lines = Arrays.asList(html.split("\n"));
List<String> lines = Arrays.asList(html.replace("../", "../../").split("\n"));
File htmlLocation = new File(getPlayerFolder(), URLEncoder.encode(playerName, "UTF-8").replace(".", "%2E"));
htmlLocation.mkdirs();
@ -106,7 +106,7 @@ public abstract class SpecificExport {
return;
}
String html = response.getContent().replace("../", "../../");
String html = response.getContent();
exportPlayerPage(name, html);
}