rust-embed v8.11.0
git clone https://git.pyrossh.dev/rust-embed
rust macro which loads files into the rust binary at compile time during release and loads the file from the fs during dev.
9e5bda6
— Mcat12
2019-09-28T18:00:55-04:00
Fix mime_guess error in Warp example
- examples/warp.rs +1 -1
examples/warp.rs
CHANGED
|
@@ -22,7 +22,7 @@ fn main() {
|
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
fn serve(path: &str) -> Result<impl Reply, Rejection> {
|
|
25
|
-
let mime = mime_guess::
|
|
25
|
+
let mime = mime_guess::from_path(path).first_or_octet_stream();
|
|
26
26
|
|
|
27
27
|
let asset: Option<Cow<'static, [u8]>> = Asset::get(path);
|
|
28
28
|
|