mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Make Rubocop happy
This commit is contained in:
parent
409ee66839
commit
6588a45880
@ -138,10 +138,13 @@ def remap_posts(find, type, ignore_case, replace = "")
|
|||||||
i = 0
|
i = 0
|
||||||
|
|
||||||
Post.raw_match(find, type).find_each do |p|
|
Post.raw_match(find, type).find_each do |p|
|
||||||
regex = case type
|
regex =
|
||||||
when 'string' then Regexp.new(Regexp.escape(find), ignore_case)
|
case type
|
||||||
when 'regex' then Regexp.new(find, ignore_case)
|
when 'string' then
|
||||||
end
|
Regexp.new(Regexp.escape(find), ignore_case)
|
||||||
|
when 'regex' then
|
||||||
|
Regexp.new(find, ignore_case)
|
||||||
|
end
|
||||||
|
|
||||||
new_raw = p.raw.gsub(regex, replace)
|
new_raw = p.raw.gsub(regex, replace)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user