diff options
Diffstat (limited to 'app/models/wiki_page.rb')
-rw-r--r-- | app/models/wiki_page.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/models/wiki_page.rb b/app/models/wiki_page.rb index 431c1e33f55..4d8cfd6368f 100644 --- a/app/models/wiki_page.rb +++ b/app/models/wiki_page.rb @@ -47,7 +47,11 @@ class WikiPage # The formatted title of this page. def title - @attributes[:title] || "" + if @attributes[:title] + @attributes[:title].gsub(/-+/, ' ') + else + "" + end end # Sets the title of this page. |