mirror of
https://github.com/hakanensari/frankfurter.git
synced 2024-11-25 04:22:28 +01:00
Use error helper in development
This commit is contained in:
parent
082ebd8640
commit
2bed405d0f
@ -9,6 +9,10 @@ configure do
|
||||
enable :cross_origin
|
||||
end
|
||||
|
||||
configure :development do
|
||||
set :show_exceptions, :after_handler
|
||||
end
|
||||
|
||||
configure :production do
|
||||
require 'newrelic_rpm'
|
||||
end
|
||||
@ -35,14 +39,14 @@ helpers do
|
||||
end
|
||||
|
||||
get '/' do
|
||||
jsonp(details: 'http://fixer.io', version: App.version)
|
||||
jsonp details: 'http://fixer.io', version: App.version
|
||||
end
|
||||
|
||||
get '/latest' do
|
||||
jsonp snapshot
|
||||
end
|
||||
|
||||
get %r((?<year>\d{4})-(?<month>\d{2})-(?<day>\d{2})) do
|
||||
get(/(?<year>\d{4})-(?<month>\d{2})-(?<day>\d{2})/) do
|
||||
process_date
|
||||
jsonp snapshot
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user