From a5af3f75af86ff0abd9964bfd69483d116c12b13 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sat, 22 Sep 2007 17:08:09 +0000 Subject: Added symbols as a legal way of specifying plugins in config.plugins (closes #9629) [tom] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7540 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- railties/lib/rails/plugin/loader.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'railties/lib/rails/plugin/loader.rb') diff --git a/railties/lib/rails/plugin/loader.rb b/railties/lib/rails/plugin/loader.rb index e935f9b34b..016bcc6c50 100644 --- a/railties/lib/rails/plugin/loader.rb +++ b/railties/lib/rails/plugin/loader.rb @@ -13,7 +13,7 @@ module Rails def initialize(initializer, directory) @initializer = initializer @directory = directory - @name = File.basename(directory) + @name = File.basename(directory).to_sym end def load @@ -126,7 +126,7 @@ module Rails end if !explicitly_enabled? && !other_plugin_loader.explicitly_enabled? - name <=> other_plugin_loader.name + name.to_s <=> other_plugin_loader.name.to_s elsif registered_plugins.include?(:all) && (!explicitly_enabled? || !other_plugin_loader.explicitly_enabled?) effective_index = explicitly_enabled? ? registered_plugins.index(name) : registered_plugins.index(:all) other_effective_index = other_plugin_loader.explicitly_enabled? ? @@ -138,7 +138,7 @@ module Rails end else - name <=> other_plugin_loader.name + name.to_s <=> other_plugin_loader.name.to_s end end end -- cgit v1.2.3