Sha256: 84b6002b95f06715a52e6a4a6e7550fce38f0418a9cb6a5685ffce8063755cca
Contents?: true
Size: 536 Bytes
Versions: 1
Compression:
Stored size: 536 Bytes
Contents
require "thomler/version" require "thomler/array" require "thomler/routing" module Thomler class Application def call env if env['PATH_INFO'] == '/favicon.ico' return [404, {'Content-Type' => 'text/html'}, []] end klass, act = get_controller_and_action(env) controller = klass.new(env) text = controller.send(act) [200, {'Content-Type' => 'text/html'}, [text]] end end class Controller def initialize env @env = env end def env @env end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
thomler-0.1.4 | lib/thomler.rb |