Sha256: 4631420bb64411d504c4b7ba5c1b512a245ce3f23b3c0f669e6983f6f30b7cfe
Contents?: true
Size: 471 Bytes
Versions: 2
Compression:
Stored size: 471 Bytes
Contents
before '/*.json' do content_type 'application/json' end before '/*' do @title = 'Bowl' end get '/' do haml :index end get '/plugins' do @title = "Plug-ins" haml :plugins end get '/plugin/:name' do name = params['name'] halt 404, "plugin \"#{name}\" not found" unless plugins.has_key? name @plugin = plugins[name] @title = "plugin/#{name}" halt 500, "Error : #{@plugin.message} at #{Plugin.list[name]}" if @plugin.kind_of? Error haml :plugin end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
bowl-0.0.2 | lib/bowl/app/controllers/main.rb |
bowl-0.0.1 | lib/bowl/app/controllers/main.rb |