From ebd2b174df29e04ea46e496cd8fe0f4fe6192ae2 Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Mon, 14 Aug 2017 10:44:48 +0200 Subject: [PATCH] Removed ruby 2.4.1 warming "warning: regular expression has redundant nested repeat operator '*'". --- lib/core_ext/string.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/core_ext/string.rb b/lib/core_ext/string.rb index f93035d93..3db6fe1fb 100644 --- a/lib/core_ext/string.rb +++ b/lib/core_ext/string.rb @@ -306,7 +306,7 @@ class String string.gsub!(%r\
[[:space:]]*(([[:space:]]*)){2,}\im, '

\3') string.gsub!(%r\[[:space:]]*(
[[:space:]]*){3,}[[:space:]]*
\im, '

') string.gsub!(%r\
[[:space:]]*(
[[:space:]]*){1,}[[:space:]]*
\im, '
 
') - string.gsub!(%r\
[[:space:]]*(
[[:space:]]*{1,}
[[:space:]]*){2,}
\im, '
 
') + string.gsub!(%r\
[[:space:]]*(
[[:space:]]*
[[:space:]]*){2,}
\im, '
 
') string.gsub!(%r\

[[:space:]]*

([[:space:]]*){2,}[[:space:]]*\im, '


') string.gsub!(%r{

[[:space:]]*

([[:space:]]*)+

[[:space:]]*

}im, '

') string.gsub!(%r\(
[[:space:]]*
[[:space:]]*){2,}\im, '
')