Skip to content

Commit 1c2d356

Browse files
committed
feat: Allow unknown extensions in static assets
1 parent 0579fc8 commit 1c2d356

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,9 @@ serde_json = { version = "1" }
4949
# Error declaration/context
5050
snafu = "0.8.8"
5151
# Serve static assets directly from the binary
52-
# Wait for https://github.com/M4SS-Code/static-serve/pull/8
52+
# Using dev branch because of: https://github.com/M4SS-Code/static-serve/pull/8
5353
# static-serve = "0.3.0"
54-
static-serve = { git = "https://github.com/angrynode/static-serve", branch = "infallible-mimetype", features = [ "infallible" ] }
54+
static-serve = { git = "https://github.com/M4SS-Code/static-serve" }
5555
# Extra tokio features:
5656
# fs: Filesystem IO integration
5757
# rt: Single-threaded runtime

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ use state::error::AppStateError;
1414

1515
pub fn router(state: state::AppState) -> Router {
1616
// Embed the assets in the binary, generating the static_router function
17-
embed_assets!("assets");
17+
embed_assets!("assets", allow_unknown_extensions = true);
1818

1919
Router::new()
2020
// Register dynamic routes

0 commit comments

Comments
 (0)