diff --git a/app/helpers/wiki_external_filter_helper.rb b/app/helpers/wiki_external_filter_helper.rb
index a96d60a..efe5c9b 100644
--- a/app/helpers/wiki_external_filter_helper.rb
+++ b/app/helpers/wiki_external_filter_helper.rb
@@ -80,9 +80,13 @@ module WikiExternalFilterHelper
def build_forced(text, attachments, info)
+ # joining splitted args
+ # not necessary from v2.1.0
+ text = text.join(", ")
+
if info['replace_attachments'] and attachments
attachments.each do |att|
- text.to_s.gsub!(/#{att.filename.downcase}/i, att.diskfile)
+ text.gsub!(/#{att.filename.downcase}/i, att.diskfile)
end
end
@@ -90,7 +94,7 @@ module WikiExternalFilterHelper
content = []
errors = ""
- text = text.first.to_s.gsub("
", "\n")
+ text = text.gsub("
", "\n")
Rails.logger.debug "\n Text #{text} \n"
info['outputs'].each do |out|