From fb5fc626042e8d1b99879e74d8e74d2f45283b0c Mon Sep 17 00:00:00 2001 From: mikg0 Date: Mon, 13 May 2013 15:04:52 +0300 Subject: [PATCH] Fix file link recognition in HtmlEditorField.js The new file_link format ([file_link,id=\d+]) uses a comma which was not reflected in the regex. --- javascript/HtmlEditorField.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javascript/HtmlEditorField.js b/javascript/HtmlEditorField.js index 9306ef2ea..efe269ff3 100644 --- a/javascript/HtmlEditorField.js +++ b/javascript/HtmlEditorField.js @@ -716,7 +716,7 @@ ss.editorWrappers['default'] = ss.editorWrappers.tinyMCE; email: RegExp.$1, Description: title }; - } else if(href.match(/^(assets\/.*)$/) || href.match(/^\[file_link\s*(?:%20)?id=([0-9]+)\]?(#.*)?$/)) { + } else if(href.match(/^(assets\/.*)$/) || href.match(/^\[file_link\s*(?:\s*|%20|,)?id=([0-9]+)\]?(#.*)?$/)) { return { LinkType: 'file', file: RegExp.$1,