3
0
mirror of https://github.com/Qortal/qortal.git synced 2025-02-12 02:05:50 +00:00

Fixed bug in HTML parser

This commit is contained in:
CalDescent 2023-03-03 12:39:44 +00:00
parent b17035c864
commit d51f9368ef

View File

@ -21,7 +21,7 @@ public class HTMLParser {
public HTMLParser(String resourceId, String inPath, String prefix, boolean usePrefix, byte[] data,
String qdnContext, Service service, String identifier) {
String inPathWithoutFilename = inPath.substring(0, inPath.lastIndexOf('/'));
String inPathWithoutFilename = inPath.contains("/") ? inPath.substring(0, inPath.lastIndexOf('/')) : "";
this.linkPrefix = usePrefix ? String.format("%s/%s%s", prefix, resourceId, inPathWithoutFilename) : "";
this.data = data;
this.qdnContext = qdnContext;