Skip to content

Commit 4eb26a1

Browse files
committed
Minor Fixes
1 parent d809d1f commit 4eb26a1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

static-files-middleware/src/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,3 @@ mod middleware;
22
pub use middleware::*;
33
mod files_access;
44
pub use files_access::*;
5-
pub const DEFAULT_FOLDER: &str = "./wwwroot";

static-files-middleware/src/middleware.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ pub struct StaticFilesMiddleware {
3434
}
3535

3636
impl StaticFilesMiddleware {
37+
pub const DEFAULT_FOLDER: &'static str = "./wwwroot";
3738
pub fn new(mappings: Option<Vec<FilesMapping>>, index_files: Option<Vec<String>>) -> Self {
3839
let index_files = if let Some(index_file_to_check) = index_files {
3940
let mut index_files_result = Vec::with_capacity(index_file_to_check.len());
@@ -191,7 +192,7 @@ impl HttpServerMiddleware for StaticFilesMiddleware {
191192

192193
if let Some(result) = self
193194
.handle_folder(
194-
super::DEFAULT_FOLDER,
195+
Self::DEFAULT_FOLDER,
195196
ctx.request.http_path.as_str_from_segment(0),
196197
)
197198
.await

0 commit comments

Comments
 (0)