Created
December 26, 2009 13:14
-
-
Save reactormonk/263947 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
require 'rango/mixins/rendering' | |
class Application < Merb::Controller | |
include Rango::ExplicitRendering | |
def scope | |
super.tap do |scope| | |
scope.extend ResourceHelper | |
scope.instance_variable_set("@params", self.request.params) | |
scope.extend Merb::Helpers | |
scope.extend Merb::AssetsMixin | |
end | |
end | |
end | |
module ResourceHelper | |
# Port from Merb::Controller | |
def resource(*args) | |
args << @params | |
Merb::Router.resource(*args) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment