diff options
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/generators/named_base.rb | 6 | ||||
-rw-r--r-- | railties/lib/rails/generators/rails/controller/templates/controller.rb | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/railties/lib/rails/generators/named_base.rb b/railties/lib/rails/generators/named_base.rb index b060b4330b..fcd289b2dd 100644 --- a/railties/lib/rails/generators/named_base.rb +++ b/railties/lib/rails/generators/named_base.rb @@ -84,11 +84,11 @@ module Rails end def namespaced_class_path - @namespaced_class_path ||= [namespace_path] + @class_path + @namespaced_class_path ||= [namespaced_path] + @class_path end - def namespace_path - @namespace_path ||= namespace.name.split("::").map {|m| m.underscore }[0] + def namespaced_path + @namespaced_path ||= namespace.name.split("::").map {|m| m.underscore }[0] end def class_name diff --git a/railties/lib/rails/generators/rails/controller/templates/controller.rb b/railties/lib/rails/generators/rails/controller/templates/controller.rb index 0f15125649..633e0b3177 100644 --- a/railties/lib/rails/generators/rails/controller/templates/controller.rb +++ b/railties/lib/rails/generators/rails/controller/templates/controller.rb @@ -1,5 +1,5 @@ <% if namespaced? -%> -require_dependency "<%= namespace_path %>/application_controller" +require_dependency "<%= namespaced_path %>/application_controller" <% end -%> <% module_namespacing do -%> |