diff options
author | Yuji Yaginuma <yuuji.yaginuma@gmail.com> | 2019-07-09 07:24:54 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-09 07:24:54 +0900 |
commit | 60809e0e1f36da730d0765a1dd781c52366053fb (patch) | |
tree | 623dc67b83be1037dceaa96003a44f7a80f35ca1 /activerecord | |
parent | 974a59fd9a648e8c7b6ac32ff609d7325cab219d (diff) | |
parent | aec52c0d1e82c1a9c5c0c4f2674f64d373330a53 (diff) | |
download | rails-60809e0e1f36da730d0765a1dd781c52366053fb.tar.gz rails-60809e0e1f36da730d0765a1dd781c52366053fb.tar.bz2 rails-60809e0e1f36da730d0765a1dd781c52366053fb.zip |
Merge pull request #36612 from y-yagi/make_setup_works_when_using_with_locales_other_than_en
Make "bin/setup" works when using PostgreSQL with locales other than en locale
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb index 82de52de50..0a7c6d8ac4 100644 --- a/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb @@ -46,7 +46,7 @@ module ActiveRecord conn = PG.connect(conn_params) ConnectionAdapters::PostgreSQLAdapter.new(conn, logger, conn_params, config) rescue ::PG::Error => error - if error.message.include?("does not exist") + if error.message.include?(conn_params[:dbname]) raise ActiveRecord::NoDatabaseError else raise |