diff options
author | yalab <rudeboyjet@gmail.com> | 2010-10-01 01:26:22 +0900 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2010-09-30 13:53:06 -0300 |
commit | 91deff08c940f16ed149e7628694faff0393fe0a (patch) | |
tree | ba71ccee1a58f616ee0cea19c44cc485c8524f4f /activerecord/lib/active_record/railties | |
parent | 33733d5d1de0eae6e25ee3f28aa69727f782086c (diff) | |
download | rails-91deff08c940f16ed149e7628694faff0393fe0a.tar.gz rails-91deff08c940f16ed149e7628694faff0393fe0a.tar.bz2 rails-91deff08c940f16ed149e7628694faff0393fe0a.zip |
Fix 'rake db:create' is ignore encoding when using postgres [#5717 state:resolved]
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
Diffstat (limited to 'activerecord/lib/active_record/railties')
-rw-r--r-- | activerecord/lib/active_record/railties/databases.rake | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/railties/databases.rake b/activerecord/lib/active_record/railties/databases.rake index 389a5d5884..58c705c8b2 100644 --- a/activerecord/lib/active_record/railties/databases.rake +++ b/activerecord/lib/active_record/railties/databases.rake @@ -108,7 +108,7 @@ namespace :db do end end when 'postgresql' - @encoding = config[:encoding] || ENV['CHARSET'] || 'utf8' + @encoding = config['encoding'] || ENV['CHARSET'] || 'utf8' begin ActiveRecord::Base.establish_connection(config.merge('database' => 'postgres', 'schema_search_path' => 'public')) ActiveRecord::Base.connection.create_database(config['database'], config.merge('encoding' => @encoding)) |