Skip to content

Commit

Permalink
Remove unnecessary call to whitelistField.set. Fixes eclipse-jdtls#610
Browse files Browse the repository at this point in the history
Signed-off-by: Fred Bricon <[email protected]>
  • Loading branch information
fbricon committed Apr 3, 2018
1 parent 03470c4 commit 7be84e8
Showing 1 changed file with 0 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ public class JavaDoc2MarkdownConverter extends AbstractJavaDocConverter {
options.autoLinks = true;
options.reverseHtmlSmartPunctuation = true;
remark = new Remark(options);

//Stop remark from stripping file and jdt protocols in an href
try {
Field cleanerField = Remark.class.getDeclaredField("cleaner");
Expand All @@ -52,7 +51,6 @@ public class JavaDoc2MarkdownConverter extends AbstractJavaDocConverter {
Whitelist w = (Whitelist) whitelistField.get(c);

w.addProtocols("a", "href", "file", "jdt");
whitelistField.set(whitelistField.get(c), w);
} catch (NoSuchFieldException | SecurityException | IllegalArgumentException | IllegalAccessException e) {
JavaLanguageServerPlugin.logException("Unable to modify jsoup to include file and jdt protocols", e);
}
Expand Down

0 comments on commit 7be84e8

Please sign in to comment.