Open sandric opened 11 years ago
Keeps the folks who don't understand it from using it. ;-p
Jeremy Jackson
On Jun 22, 2013, at 3:41 AM, sandric notifications@github.com wrote:
In routes we have
Mercury::Engine.routes.draw do get '/editor(/*requested_uri)' => "mercury#edit", :as => :mercury_editor
scope '/mercury' do get ':type/:resource' => "mercury#resource" get 'snippets/:name/options' => "mercury#snippet_options" get 'snippets/:name/preview' => "mercury#snippet_preview" end end But in mercury.js config file options and preview are routed through GET method, and with .html file extension:
snippets: { method: 'POST', optionsUrl: '/mercury/snippets/:name/options.html', previewUrl: '/mercury/snippets/:name/preview.html' }, So after open testing snippets panel and paste snippet from it, I got
ActionController::RoutingError (No route matches [POST] "/mercury/snippets/example/options.html"):
Changing one routes.rb to post or mercury.js to get the problem disappears.
Is anyone else saw this?
— Reply to this email directly or view it on GitHub.
In routes we have
But in mercury.js config file options and preview are routed through GET method, and with .html file extension:
So after open testing snippets panel and paste snippet from it, I got
ActionController::RoutingError (No route matches [POST] "/mercury/snippets/example/options.html"):
Changing one routes.rb to post or mercury.js to get the problem disappears.
Is anyone else saw this?