Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Support escaped / characters in markdown URLs

Adds support to the pagedown Markdown converter for URLs where the
forward slashes in an absolute URL have been entity escaped (as they
are from Backbone.Model.escape()), e.g. http://example.com

Closes #124
  • Loading branch information...
commit d37f864a4b74ae0fa83cf822ffb6069cdfa71cac 1 parent 492cdd6
@malclocke malclocke authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  vendor/assets/javascripts/Markdown.Converter.js
View
2  vendor/assets/javascripts/Markdown.Converter.js
@@ -1298,7 +1298,7 @@ else
if (match == "~D") // escape for dollar
return "%24";
if (match == ":") {
- if (offset == len - 1 || /[0-9\/]/.test(url.charAt(offset + 1)))
+ if (offset == len - 1 || /[0-9\/]/.test(url.charAt(offset + 1)) || url.substr(offset + 1, 6) === '/')
return ":"
}
return "%" + match.charCodeAt(0).toString(16);
Please sign in to comment.
Something went wrong with that request. Please try again.