diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index 30f018b..fc0b7ce 100644 --- a/src/main.rs +++ b/src/main.rs @@ -442,7 +442,7 @@ async fn build_response<C: Controller>( .body("redirecting".into()) .unwrap()); } - return get_routes::view_blob(entr, params, controller, ctx); + return get_routes::get_blob(entr, params, controller, ctx); } tree = ctx.repo.find_tree(entr.id()); @@ -528,6 +528,10 @@ impl Context { parent_commits, ) } + + fn file_name(&self) -> Option<&str> { + self.path.file_name().and_then(|x| x.to_str()) + } } fn render_markdown(input: &str) -> String { |