Skip to content

Commit

Permalink
Fix 'rake db:create' is ignore encoding when using postgres [#5717 st…
Browse files Browse the repository at this point in the history
…ate:resolved]

Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
  • Loading branch information
yalab authored and spastorino committed Sep 30, 2010
1 parent 33733d5 commit 91deff0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activerecord/lib/active_record/railties/databases.rake
Expand Up @@ -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))
Expand Down

0 comments on commit 91deff0

Please sign in to comment.