Skip to content

Commit

Permalink
See #188
Browse files Browse the repository at this point in the history
  • Loading branch information
enridaga committed Dec 21, 2021
1 parent af8c496 commit 4aeae03
Showing 1 changed file with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ static Charset getCharsetArgument(Properties properties) {
return charset;
}

@Deprecated
static String getRootArgument(Properties properties, URL url) {
if (url != null) {
return getRootArgument(properties, url.toString());
Expand All @@ -106,6 +107,23 @@ static String getRootArgument(Properties properties, URL url) {
}
}

static String getRootArgument(Properties properties) {
try {
return getRootArgument(properties, Triplifier.getLocation(properties));
} catch (MalformedURLException e) {
log.error("Malformed url", e);
return getRootArgument(properties, (String) null);
}
}

/**
* Implementation to be moved to getRootArgument(Properties)
*
* @param properties
* @param url
* @return
*/
@Deprecated
static String getRootArgument(Properties properties, String url) {
if (url != null) {
String root = null;
Expand Down

0 comments on commit 4aeae03

Please sign in to comment.