From 2b4848566cfb0e8bc4f1a2a970f111222e5767c4 Mon Sep 17 00:00:00 2001 From: Rob Speer Date: Wed, 22 Aug 2012 14:09:51 -0400 Subject: [PATCH] Fix names created with the 'New' button. Previously, a page created with the 'New' button would get all of its spaces turned into the + symbol when submitted, which Gollum would then convert into "-plus-" in the title. So, for example, a request to create a page called "Test page" would instead get "test plus page". This change changes + to - in the parameter received by /create/. --- lib/gollum/frontend/app.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/gollum/frontend/app.rb b/lib/gollum/frontend/app.rb index 30895f28..c69cede2 100644 --- a/lib/gollum/frontend/app.rb +++ b/lib/gollum/frontend/app.rb @@ -172,7 +172,7 @@ module Precious end get '/create/*' do - wikip = wiki_page(params[:splat].first) + wikip = wiki_page(params[:splat].first.gsub('+', '-')) @name = wikip.name.to_url @path = wikip.path