Skip to content

Commit 73b0065

Browse files
author
James Leigh
committed
Issue #69: Ensure path is never null
Signed-off-by: James Leigh <james.leigh@ontotext.com>
1 parent 2d51b28 commit 73b0065

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

core/util/src/main/java/org/eclipse/rdf4j/common/net/ParsedIRI.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -322,10 +322,6 @@ public ParsedIRI(String iri)
322322
/**
323323
* Constructs a hierarchical IRI from the given components.
324324
* <p>
325-
* If a scheme is given then the path, if also given, must either be empty or begin with a slash character
326-
* ({@code '/'}). Otherwise a component of the new IRI may be left undefined by passing {@code null} for
327-
* the corresponding parameter or, in the case of the {@code port} parameter, by passing {@code -1}.
328-
* <p>
329325
* This constructor first builds a IRI string from the given components according to the rules specified
330326
* in <a href="http://www.ietf.org/rfc/rfc3987.txt">RFC&nbsp;3987</a>
331327
* </p>
@@ -353,7 +349,7 @@ public ParsedIRI(String scheme, String userInfo, String host, int port, String p
353349
this.userInfo = userInfo;
354350
this.host = host;
355351
this.port = port;
356-
this.path = scheme != null && path == null ? "" : path;
352+
this.path = path == null ? "" : path;
357353
this.query = query;
358354
this.fragment = fragment;
359355
}

0 commit comments

Comments
 (0)