We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8335b55 commit c401788Copy full SHA for c401788
public/js/libs/autolink.js
@@ -5,11 +5,13 @@ jQuery.fn.autolink = function() {
5
.each(function() {
6
$(this).each(function() {
7
if (re.test($(this).text()))
8
- $(this).replaceWith(
9
- $("<span />").html(
10
- this.nodeValue.replace(re, "<a href='$1'>$1</a>")
11
- )
12
- );
+ if($(this).parents().filter('code').length === 0) {
+ $(this).replaceWith(
+ $("<span />").html(
+ this.nodeValue.replace(re, "<a href='$1'>$1</a>")
+ )
13
+ );
14
+ };
15
});
16
17
};
0 commit comments