Last active
August 29, 2015 13:57
-
-
Save syntruth/9783290 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class RackPathInfoFix | |
def initialize(app) | |
@app = app | |
end | |
def call(env) | |
env['PATH_INFO'] = File.join(env['SCRIPT_NAME'], env['PATH_INFO']) | |
@app.call env | |
end | |
end | |
use RackPathInfoFix | |
map '/assets' do | |
run IPTApp.sprockets | |
end | |
map '/' do | |
run IPTApp | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment