Skip to content

Commit

Permalink
allow user to be omitted, will end up being root
Browse files Browse the repository at this point in the history
  • Loading branch information
serprex committed Apr 30, 2024
1 parent f9dff0b commit 221dedd
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions nexus/analyzer/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -924,7 +924,8 @@ fn parse_db_options(db_type: DbType, with_options: &[SqlOption]) -> anyhow::Resu
.context("unable to parse port as valid int")?,
user: opts
.get("user")
.context("no username specified")?
.cloned()
.unwrap_or_default()
.to_string(),
password: opts
.get("password")
Expand All @@ -942,8 +943,8 @@ fn parse_db_options(db_type: DbType, with_options: &[SqlOption]) -> anyhow::Resu
.unwrap_or_default(),
compression: opts
.get("compression")
.and_then(|s| s.parse::<i8>().ok())
.unwrap_or_default() as u32,
.and_then(|s| s.parse::<u32>().ok())
.unwrap_or_default(),
disable_tls: opts
.get("disable_tls")
.and_then(|s| s.parse::<bool>().ok())
Expand Down

0 comments on commit 221dedd

Please sign in to comment.