c831ff67e4
- Remove unnecessary checks for `ctx.Repo.TreePath`, because it will already early-return if it's empty. - Simplify `performBlame` to extract the repoPath from the context. - Don't render the topics, as they are not shown in the blame page (there's a condition in the template for the blame page). - Fix that `performBlame` doesn't call `NotFound`, it should instead only return the error. - Fix that the error handlings call `ServerError` instead of `NotFound`. - Simplify `bypass-blame-ignore` to use `ctx.FormBool`. - Remove `TreeLink`, `HasParentPath` and `ParentPath` as it's not used in the blame template. - Inline `BranchLink` and `RawFileLink` string operations. - Move around `NumLines` to make it clear the error is handled. - Less code, less things the code does, more readable and thus more maintanable! (cherry picked from commit e02baca55c0a3ed6a806f276c8e3cf2995a88967) (cherry picked from commit 74e00620ca4de9a2aaa51f30fdf8136b581c7a21) |
||
---|---|---|
.. | ||
api | ||
common | ||
install | ||
private | ||
utils | ||
web | ||
init.go |