diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/main.rs b/src/main.rs index 6d8693f..70cd9d6 100644 --- a/src/main.rs +++ b/src/main.rs @@ -66,9 +66,10 @@ fn main() { if let Some(matches) = matches.subcommand_matches("init") { let config = pjournal::models::Config { - strava_client_id: matches.value_of("strava_client_id").unwrap(), - strava_client_secret: matches.value_of("strava_client_secret").unwrap(), - rocket_secret_key: matches.value_of("rocket_secret_key").unwrap(), + strava_client_id: matches.value_of("strava_client_id").unwrap().to_string(), + strava_client_secret: matches.value_of("strava_client_secret").unwrap().to_string(), + rocket_secret_key: matches.value_of("rocket_secret_key").unwrap().to_string(), + singleton: true, }; pjournal::db::create_config(&conn, &config).unwrap(); @@ -80,6 +81,6 @@ fn main() { let config = pjournal::server::Params { base_url: base_url.to_string(), }; - pjournal::server::start(db_url, config); + pjournal::server::start(conn, db_url, config); } } |