This file contains hidden or 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
module ShallowNestedRoutes | |
def self.included(base) | |
base.extend(ClassMethods) | |
end | |
module ClassMethods | |
# Pass in the name of the parent class | |
def set_shallow_nested_route_parent(parent) | |
parent = parent.to_s | |
# Override these methods so they set the prefix path before a call and reset it afterward. |