aboutsummaryrefslogtreecommitdiff
path: root/src/forms.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/forms.rs')
-rw-r--r--src/forms.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/forms.rs b/src/forms.rs
index b987aca..0a2019c 100644
--- a/src/forms.rs
+++ b/src/forms.rs
@@ -1,5 +1,3 @@
-use std::os::unix::prelude::OsStrExt;
-
use hyper::http::request::Parts;
use serde::Deserialize;
use sputnik::html_escape;
@@ -34,7 +32,7 @@ pub fn edit_text_form<'a, C: Controller>(
} else {
"Creating"
},
- ctx.path.file_name().unwrap().to_str().unwrap()
+ ctx.path.file_name().unwrap()
),
header: data
.oid
@@ -129,7 +127,7 @@ pub fn upload_form<'a, C: Controller>(
ctx: &'a Context,
parts: &Parts,
) -> Page {
- let filename = ctx.path.file_name().unwrap().to_str().unwrap();
+ let filename = ctx.path.file_name().unwrap();
Page {
title: format!("Uploading {}", filename),
// TODO: add input for commit message