File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
src/Illuminate/Foundation Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -76,20 +76,20 @@ public static function configureUnpooledPostgresConnection(Application $app): vo
76
76
77
77
if (str_contains ($ host , 'pg.laravel.cloud ' ) &&
78
78
str_contains ($ host , '-pooler ' )) {
79
+ $ app ['config ' ]->set (
80
+ 'database.connections.pgsql-unpooled ' ,
81
+ array_merge ($ app ['config ' ]->get ('database.connections.pgsql ' ), [
82
+ 'host ' => str_replace ('-pooler ' , '' , $ host ),
83
+ ])
84
+ );
85
+
79
86
$ app ['config ' ]->set (
80
87
'database.connections.pgsql.options ' ,
81
88
array_merge (
82
89
$ app ['config ' ]->get ('database.connections.pgsql.options ' , []),
83
90
[PDO ::ATTR_EMULATE_PREPARES => true ],
84
91
),
85
92
);
86
-
87
- $ app ['config ' ]->set (
88
- 'database.connections.pgsql-unpooled ' ,
89
- array_merge ($ app ['config ' ]->get ('database.connections.pgsql ' ), [
90
- 'host ' => str_replace ('-pooler ' , '' , $ host ),
91
- ])
92
- );
93
93
}
94
94
}
95
95
You can’t perform that action at this time.
0 commit comments