Update to postgres 3.0 beta

This commit is contained in:
Simon Binder 2023-10-31 22:10:51 +01:00
parent ddc864a7c2
commit 7106dfc519
No known key found for this signature in database
GPG Key ID: 7891917E4147B8C0
5 changed files with 6 additions and 6 deletions

View File

@ -26,7 +26,7 @@ void main() async {
username: 'postgres',
password: 'postgres',
),
sessionSettings: SessionSettings(
settings: ConnectionSettings(
// If you expect to talk to a Postgres database over a public connection,
// please use SslMode.verifyFull instead.
sslMode: SslMode.disable,

View File

@ -26,7 +26,7 @@ void main() async {
username: 'postgres',
password: 'postgres',
),
sessionSettings: pg.SessionSettings(
settings: pg.ConnectionSettings(
// If you expect to talk to a Postgres database over a public connection,
// please use SslMode.verifyFull instead.
sslMode: pg.SslMode.disable,

View File

@ -8,12 +8,12 @@ import 'package:postgres/postgres.dart';
class PgDatabase extends DelegatedDatabase {
PgDatabase({
required Endpoint endpoint,
SessionSettings? sessionSettings,
ConnectionSettings? settings,
bool logStatements = false,
bool enableMigrations = true,
}) : super(
_PgDelegate(
() => Connection.open(endpoint, sessionSettings: sessionSettings),
() => Connection.open(endpoint, settings: settings),
true,
enableMigrations,
),

View File

@ -11,7 +11,7 @@ environment:
dependencies:
collection: ^1.16.0
drift: ^2.0.0
postgres: ^3.0.0-0
postgres: ^3.0.0-beta.1
meta: ^1.8.0
uuid: ^4.1.0

View File

@ -18,7 +18,7 @@ class PgExecutor extends TestExecutor {
username: 'postgres',
password: 'postgres',
),
sessionSettings: pg.SessionSettings(sslMode: pg.SslMode.disable),
settings: pg.ConnectionSettings(sslMode: pg.SslMode.disable),
));
}