From 8412200f90c239cbf12bb32b5246d0104306f6c2 Mon Sep 17 00:00:00 2001 From: Carlos Paramio Date: Tue, 4 Nov 2008 20:32:52 +0100 Subject: [PATCH] Change usage of defined? to check the rubygems constant existance by a rescue block on boot.rb for Ruby 1.9 compatibility Signed-off-by: Jeremy Kemper --- railties/environments/boot.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/railties/environments/boot.rb b/railties/environments/boot.rb index 57c256e438..0a516880ca 100644 --- a/railties/environments/boot.rb +++ b/railties/environments/boot.rb @@ -67,7 +67,7 @@ module Rails class << self def rubygems_version - Gem::RubyGemsVersion if defined? Gem::RubyGemsVersion + Gem::RubyGemsVersion rescue nil end def gem_version