Skip to content

Commit 4c65af1

Browse files
committed
only convert if nessesary
1 parent 236a51c commit 4c65af1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

routers/web/admin/repos.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ package admin
77
import (
88
"net/http"
99
"net/url"
10-
"strconv"
1110
"strings"
1211

1312
"code.gitea.io/gitea/models"
@@ -111,7 +110,7 @@ func UnadoptedRepos(ctx *context.Context) {
111110
func AdoptOrDeleteRepository(ctx *context.Context) {
112111
dir := ctx.FormString("id")
113112
action := ctx.FormString("action")
114-
page := ctx.FormInt("page")
113+
page := ctx.FormString("page")
115114
q := ctx.FormString("q")
116115

117116
dirSplit := strings.SplitN(dir, "/", 2)
@@ -162,5 +161,5 @@ func AdoptOrDeleteRepository(ctx *context.Context) {
162161
}
163162
ctx.Flash.Success(ctx.Tr("repo.delete_preexisting_success", dir))
164163
}
165-
ctx.Redirect(setting.AppSubURL + "/admin/repos/unadopted?search=true&q=" + url.QueryEscape(q) + "&page=" + strconv.Itoa(page))
164+
ctx.Redirect(setting.AppSubURL + "/admin/repos/unadopted?search=true&q=" + url.QueryEscape(q) + "&page=" + page)
166165
}

0 commit comments

Comments
 (0)