aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib
diff options
context:
space:
mode:
authorNat Welch <nat@natwelch.com>2011-08-21 15:54:59 -0700
committerNat Welch <nat@natwelch.com>2011-08-21 15:54:59 -0700
commit0c893443e0720bb1316599d990c0e1013eaac8ab (patch)
treed08dbe97692dacf659de7dc52781eef21b03e372 /activerecord/lib
parent63d3809e31cc9c0ed3b2e30617310407ae614fd4 (diff)
downloadrails-0c893443e0720bb1316599d990c0e1013eaac8ab.tar.gz
rails-0c893443e0720bb1316599d990c0e1013eaac8ab.tar.bz2
rails-0c893443e0720bb1316599d990c0e1013eaac8ab.zip
Fixes bug with schema dumper when using with Padrino.
Diffstat (limited to 'activerecord/lib')
-rw-r--r--activerecord/lib/active_record/schema_dumper.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/schema_dumper.rb b/activerecord/lib/active_record/schema_dumper.rb
index 6fe305f843..6eadba6238 100644
--- a/activerecord/lib/active_record/schema_dumper.rb
+++ b/activerecord/lib/active_record/schema_dumper.rb
@@ -40,7 +40,7 @@ module ActiveRecord
def header(stream)
define_params = @version ? ":version => #{@version}" : ""
- if stream.respond_to?(:external_encoding)
+ if !stream.external_encoding.nil?
stream.puts "# encoding: #{stream.external_encoding.name}"
end