1 2 3 4 5 6 7 8
use crate::errors::ConfigError; pub fn validate_postgres_url(url: &str) -> Result<(), ConfigError> { if !url.starts_with("postgres://") && !url.starts_with("postgresql://") { return Err(ConfigError::InvalidPostgresUrl); } Ok(()) }