Merge pull request 'Move dotenv call to before load_config' (#289) from 284-load-env-before-parsing-config into main
All checks were successful
Push Workflows / rustfmt (push) Successful in 13s
Push Workflows / mdbook (push) Successful in 13s
Push Workflows / docker-build (push) Successful in 32s
Push Workflows / clippy (push) Successful in 1m0s
Push Workflows / docs (push) Successful in 1m26s
Push Workflows / mdbook-server (push) Successful in 1m17s
Push Workflows / leptos-test (push) Successful in 1m43s
Push Workflows / test (push) Successful in 1m59s
Push Workflows / build (push) Successful in 2m9s
Push Workflows / nix-build (push) Successful in 5m45s

Reviewed-on: #289
This commit was merged in pull request #289.
This commit is contained in:
2025-12-01 23:53:39 +00:00

View File

@@ -27,6 +27,9 @@ async fn main() {
info!("\n{}", include_str!("../ascii_art.txt"));
use dotenvy::dotenv;
dotenv().ok();
let config = load_config().unwrap_or_else(|err| {
error!("Failed to load configuration: {}", err);
std::process::exit(1);
@@ -41,9 +44,6 @@ async fn main() {
info!("Starting Leptos server...");
use dotenvy::dotenv;
dotenv().ok();
debug!("Running database migrations...");
let mut db_conn = state.get_db_conn().unwrap_or_else(|err| {