aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Florisson2014-02-27 09:49:45 +0100
committerMarc Florisson2014-02-27 09:49:45 +0100
commit47c48f52afcc24ff0dc040c6bbaf4e3787b4a63f (patch)
treed550550f6a080e5637562113c13528ed7e1154cb
parente27afb28bf51403c10029cdc5317e53ede593c47 (diff)
downloadchouette-core-47c48f52afcc24ff0dc040c6bbaf4e3787b4a63f.tar.bz2
fix regexp , replcae with $'
-rw-r--r--app/models/help_page.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/models/help_page.rb b/app/models/help_page.rb
index ea9d34e44..064cdc680 100644
--- a/app/models/help_page.rb
+++ b/app/models/help_page.rb
@@ -21,10 +21,10 @@ class HelpPage
self.data ||= {}
if self.content =~ /^(---\s*\n.*?\n?)^(---\s*$\n?)/m
- self.content = $POSTMATCH
+ self.content = $' # cryptic name for $POSTMATCH, but since V2.2
self.data.merge! YAML.load($1)
end
-
+
# workaround for special chars
self.content = self.content.gsub('é','é')
self.content = self.content.gsub('è','è')
@@ -66,7 +66,7 @@ class HelpPage
if page.exists?
page.load
else
- raise ActiveRecord::RecordNotFound
+ raise ActiveRecord::RecordNotFound
end
end
end