lib/devise/mapping.rb in devise-1.1.pre2 vs lib/devise/mapping.rb in devise-1.1.pre3

- old
+ new

@@ -54,15 +54,10 @@ raise "Could not find a valid mapping for #{duck}" unless mapping mapping.name end end - # Default url options which can be used as prefix. - def self.default_url_options - {} - end - def initialize(name, options) #:nodoc: @as = (options.delete(:as) || name).to_sym @klass = (options.delete(:class_name) || name.to_s.classify).to_s @name = (options.delete(:scope) || name.to_s.singularize).to_sym @@ -93,20 +88,11 @@ def as_position self.path_prefix.count("/") end # Returns the raw path using path_prefix and as. - def raw_path + def path path_prefix + as.to_s - end - - # Returns the parsed path taking into account the relative url root and raw path. - def parsed_path - returning (ActionController::Base.relative_url_root.to_s + raw_path) do |path| - self.class.default_url_options.each do |key, value| - path.gsub!(key.inspect, value.to_param) - end - end end # Create magic predicates for verifying what module is activated by this map. # Example: #