diff --git a/impl/src/lib.rs b/impl/src/lib.rs index 0399daa..2470c74 100644 --- a/impl/src/lib.rs +++ b/impl/src/lib.rs @@ -324,8 +324,7 @@ fn impl_rust_embed(ast: &syn::DeriveInput) -> syn::Result { let crate_path: syn::Path = find_attribute_values(ast, "crate_path") .last() - .map(|v| syn::parse_str(v).unwrap()) - .unwrap_or_else(|| syn::parse_str("rust_embed").unwrap()); + .map_or_else(|| syn::parse_str("rust_embed").unwrap(), |v| syn::parse_str(v).unwrap()); let mut folder_paths = find_attribute_values(ast, "folder"); if folder_paths.len() != 1 {