FIX: allow [poll] and [ul] to be used as markdown link name

This commit is contained in:
Sam 2014-12-30 14:18:46 +11:00
parent d0fe1725c8
commit 8d8b4ff781

View File

@ -1185,6 +1185,17 @@
res = this.dialect.inline[ m[1] ].call( res = this.dialect.inline[ m[1] ].call(
this, this,
text.substr( m.index ), m, previous_nodes || [] ); text.substr( m.index ), m, previous_nodes || [] );
if(!res){
// fallback
var fn = this.dialect.inline[m[1][0]];
if(fn) {
res = fn.call(
this,
text.substr( m.index ), m, previous_nodes || [] );
}
}
} }
// Default for now to make dev easier. just slurp special and output it. // Default for now to make dev easier. just slurp special and output it.
res = res || [ m[1].length, m[1] ]; res = res || [ m[1].length, m[1] ];