server: prefer immutable path

This commit is contained in:
Waldemar Heinze authored and GitHub committed 2022-11-25 00:14:29 +01:00
1 parent a3216a4550
commit a4408cfacc
1 file changed
+1 -3
+1 -3
View File
@@ -25,9 +25,7 @@ use std::sync::RwLock;
use tracing::info;
async fn index() -> actix_web::Result<NamedFile> {
let mut path = PathBuf::new();
path.push("app");
path.push("index.html");
let path = PathBuf::from(r"app/index.html");
Ok(NamedFile::open(path)?)
}