From 761b049b2e51a035eaf9c18f4d0200409848a28e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafael=20Mendon=C3=A7a=20Fran=C3=A7a?= Date: Wed, 4 Jan 2012 13:30:57 -0300 Subject: No need to use rescue block to require psych --- activerecord/lib/active_record/base.rb | 6 +----- activerecord/lib/active_record/fixtures.rb | 7 +------ activerecord/lib/active_record/fixtures/file.rb | 6 +----- 3 files changed, 3 insertions(+), 16 deletions(-) (limited to 'activerecord/lib/active_record') diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb index d29cf82dad..5ce78ca1c6 100644 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -1,8 +1,4 @@ -begin - require 'psych' -rescue LoadError -end - +require 'psych' require 'yaml' require 'set' require 'active_support/benchmarkable' diff --git a/activerecord/lib/active_record/fixtures.rb b/activerecord/lib/active_record/fixtures.rb index 9ea8cf864c..8ae09d3e27 100644 --- a/activerecord/lib/active_record/fixtures.rb +++ b/activerecord/lib/active_record/fixtures.rb @@ -1,10 +1,5 @@ require 'erb' - -begin - require 'psych' -rescue LoadError -end - +require 'psych' require 'yaml' require 'zlib' require 'active_support/dependencies' diff --git a/activerecord/lib/active_record/fixtures/file.rb b/activerecord/lib/active_record/fixtures/file.rb index 6bad36abb9..f6fc883ee0 100644 --- a/activerecord/lib/active_record/fixtures/file.rb +++ b/activerecord/lib/active_record/fixtures/file.rb @@ -1,8 +1,4 @@ -begin - require 'psych' -rescue LoadError -end - +require 'psych' require 'erb' require 'yaml' -- cgit v1.2.3