Minor fixes for #2746
This commit is contained in:
parent
4d5911dbcf
commit
9df6ce48c5
8 changed files with 937 additions and 723 deletions
|
@ -257,14 +257,13 @@ func EditWikiPost(ctx *middleware.Context, form auth.NewWikiForm) {
|
|||
ctx.Redirect(ctx.Repo.RepoLink + "/wiki/" + models.ToWikiPageURL(form.Title))
|
||||
}
|
||||
|
||||
func DeleteWikiPagePost(ctx *middleware.Context, form auth.NewWikiForm) {
|
||||
func DeleteWikiPagePost(ctx *middleware.Context) {
|
||||
pageURL := ctx.Params(":page")
|
||||
if len(pageURL) == 0 {
|
||||
pageURL = "Home"
|
||||
}
|
||||
|
||||
pageName := models.ToWikiPageName(pageURL)
|
||||
|
||||
if err := ctx.Repo.Repository.DeleteWikiPage(ctx.User, pageName); err != nil {
|
||||
ctx.Handle(500, "DeleteWikiPage", err)
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue