Skip to content

Commit 98f5a80

Browse files
committed
Build 1.3.1
1 parent 2a478a7 commit 98f5a80

File tree

3 files changed

+13
-6
lines changed

3 files changed

+13
-6
lines changed

dist/Autolinker.js

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*!
22
* Autolinker.js
3-
* 1.3.0
3+
* 1.3.1
44
*
55
* Copyright(c) 2016 Gregory Jacobs <greg@greg-jacobs.com>
66
* MIT License
@@ -240,7 +240,7 @@ Autolinker.parse = function( textOrHtml, options ) {
240240
*
241241
* Ex: 0.25.1
242242
*/
243-
Autolinker.version = '1.3.0';
243+
Autolinker.version = '1.3.1';
244244

245245

246246
Autolinker.prototype = {
@@ -1915,7 +1915,14 @@ Autolinker.htmlParser.HtmlParser = Autolinker.Util.extend( Object, {
19151915
// Push TextNodes and EntityNodes for any text found between tags
19161916
if( text ) {
19171917
textAndEntityNodes = this.parseTextAndEntityNodes( lastIndex, text );
1918-
nodes.push.apply( nodes, textAndEntityNodes );
1918+
1919+
// Note: the following 3 lines were previously:
1920+
// nodes.push.apply( nodes, textAndEntityNodes );
1921+
// but this was causing a "Maximum Call Stack Size Exceeded"
1922+
// error on inputs with a large number of html entities.
1923+
textAndEntityNodes.forEach( function( node ) {
1924+
nodes.push( node );
1925+
} );
19191926
}
19201927
}
19211928

0 commit comments

Comments
 (0)