check for both postgres and postgresql

This commit is contained in:
Wavering Ana 2025-01-29 21:42:42 -05:00
parent 01ffe80b99
commit 67e94b4483

View file

@ -24,7 +24,7 @@ pub async fn create_db_pool() -> Result<DatabasePool> {
let database_url = std::env::var("DATABASE_URL").ok();
match database_url {
Some(url) if url.starts_with("postgres://") => {
Some(url) if url.starts_with("postgres://") || url.starts_with("postgresql://") => {
info!("Using PostgreSQL database");
let pool = PgPoolOptions::new()
.max_connections(5)