Skip to content

Commit

Permalink
load and prefer psych as the YAML parser when it is available
Browse files Browse the repository at this point in the history
  • Loading branch information
tenderlove committed May 25, 2011
1 parent 03f0f3c commit e4594f7
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
5 changes: 5 additions & 0 deletions activerecord/lib/active_record/base.rb
@@ -1,3 +1,8 @@
begin
require 'psych'
rescue LoadError
end

require 'yaml'
require 'set'
require 'active_support/benchmarkable'
Expand Down
6 changes: 6 additions & 0 deletions activerecord/lib/active_record/fixtures.rb
@@ -1,4 +1,10 @@
require 'erb'

begin
require 'psych'
rescue LoadError
end

require 'yaml'
require 'csv'
require 'zlib'
Expand Down
6 changes: 6 additions & 0 deletions railties/lib/rails/commands/dbconsole.rb
@@ -1,4 +1,10 @@
require 'erb'

begin
require 'psych'
rescue LoadError
end

require 'yaml'
require 'optparse'
require 'rbconfig'
Expand Down

0 comments on commit e4594f7

Please sign in to comment.