mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-01 11:06:06 +01:00
Add the error page.
ControllerBase#NotFound() renders this page instead of redirecting to the top page.
This commit is contained in:
@@ -26,7 +26,7 @@ abstract class ControllerBase extends ScalatraFilter with ClientSideValidationFo
|
||||
}
|
||||
}
|
||||
|
||||
protected def NotFound() = redirect("/")
|
||||
protected def NotFound() = html.error("Not Found")
|
||||
protected def Unauthorized() = redirect("/")
|
||||
|
||||
}
|
||||
|
||||
4
src/main/twirl/error.scala.html
Normal file
4
src/main/twirl/error.scala.html
Normal file
@@ -0,0 +1,4 @@
|
||||
@(title: String)(implicit context: app.Context)
|
||||
@main("Error"){
|
||||
<h1>@title</h1>
|
||||
}
|
||||
Reference in New Issue
Block a user