Skip to content

Commit

Permalink
chore: cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
gbj committed Mar 31, 2024
1 parent 3e18edb commit bfac4cb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
10 changes: 4 additions & 6 deletions integrations/utils/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,10 @@ pub fn html_parts_separated(
// First check runtime env, then build time, then default:
let pkg_path = match std::env::var("CDN_PKG_PATH").ok().map(Cow::from) {
Some(path) => path,
None => {
match option_env!("CDN_PKG_PATH").map(Cow::from) {
Some(path) => path,
None => format!("/{}", options.site_pkg_dir).into(),
}
}
None => match option_env!("CDN_PKG_PATH").map(Cow::from) {
Some(path) => path,
None => format!("/{}", options.site_pkg_dir).into(),
},
};
let output_name = &options.output_name;
let nonce = use_nonce();
Expand Down
11 changes: 7 additions & 4 deletions leptos_dom/src/helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,13 @@ pub fn location_hash() -> Option<String> {
if is_server() {
None
} else {
location().hash().ok().map(|hash| match hash.chars().next() {
Some('#') => hash[1..].to_string(),
_ => hash,
})
location()
.hash()
.ok()
.map(|hash| match hash.chars().next() {
Some('#') => hash[1..].to_string(),
_ => hash,
})
}
}

Expand Down

0 comments on commit bfac4cb

Please sign in to comment.