Skip to content

Commit

Permalink
Set regexp multiline in find/replace extension. Fixes #610
Browse files Browse the repository at this point in the history
  • Loading branch information
benweet committed Dec 14, 2014
1 parent 4c7cb8c commit 88551b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion public/res/extensions/findReplace.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ define([
var textLength = text.length;
if(textLength) {
try {
var flags = caseSensitive ? 'g' : 'gi';
var flags = caseSensitive ? 'gm' : 'gmi';
text = useRegexp ? text : text.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
regex = new RegExp(text, flags);
editor.getValue().replace(regex, function(match, offset) {
Expand Down

0 comments on commit 88551b3

Please sign in to comment.