diff options
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/generators.rb | 2 | ||||
-rw-r--r-- | railties/lib/rails/generators/base.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/railties/lib/rails/generators.rb b/railties/lib/rails/generators.rb index ecd0a1c6ea..e8c7a0993b 100644 --- a/railties/lib/rails/generators.rb +++ b/railties/lib/rails/generators.rb @@ -219,7 +219,7 @@ module Rails builtin.sort! lookup("*") - others = subclasses.map{ |k| k.namespace.gsub(':generators:', ':') } + others = subclasses.map{ |k| k.namespace } others -= Rails::Generators.builtin others.sort! diff --git a/railties/lib/rails/generators/base.rb b/railties/lib/rails/generators/base.rb index 9cc342b202..37effb77db 100644 --- a/railties/lib/rails/generators/base.rb +++ b/railties/lib/rails/generators/base.rb @@ -42,7 +42,7 @@ module Rails # def self.namespace(name=nil) return super if name - @namespace ||= super.sub(/_generator$/, '') + @namespace ||= super.sub(/_generator$/, '').sub(/:generators:/, ':') end # Invoke a generator based on the value supplied by the user to the |