embeddedTransportFor function
How the embedded postmaster for config listens.
Always the Unix socket, plus loopback TCP on config's port when
enableTcp is requested and a password is configured.
Implementation
Transport embeddedTransportFor(
PostgresDatabaseConfig config, {
bool enableTcp = false,
}) => !enableTcp || config.password.isEmpty
? const UnixTransport()
: DualTransport(port: config.port, password: config.password);