mirror of
https://github.com/allankoechke/turso.git
synced 2026-11-29 09:33:48 +00:00
Database had five public ways to open a connection: connect, connect_with_encryption, connect_with_page_codec, connect_async and connect_with_encryption_async. Every new connection setting needs more variants, and the async path doubles them again. Database::connect and Database::connect_async now take a ConnectOpts that holds the encryption key and the page codec, and the other three variants are removed. ConnectOpts has no Default, so every caller goes through ConnectOpts::new() and a required argument added there later makes the compiler find every call site.