summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorGusted <postmaster@gusted.xyz>2024-11-05 21:40:44 +0100
committerGusted <postmaster@gusted.xyz>2024-11-05 22:47:34 +0100
commit310376525b8644658983073517ae81b9b5f826bf (patch)
treee34a69c86c2649e50f48e4b78f11c1f591e94927 /services
parentMerge pull request '[PORT] Refactor the DB migration system slightly (gitea#3... (diff)
downloadforgejo-310376525b8644658983073517ae81b9b5f826bf.tar.xz
forgejo-310376525b8644658983073517ae81b9b5f826bf.zip
[CHORE] Use forked `binding` library
- Use the forked [binding](https://code.forgejo.org/go-chi/binding) library. This library has two benefits, it removes the usage of `github.com/goccy/go-json` (has no benefit as the minimo library is also using it). It adds the `TrimSpace` feature, which will during the binding part trim the spaces around the value it got from the form, this is done before validation.
Diffstat (limited to 'services')
-rw-r--r--services/forms/admin.go2
-rw-r--r--services/forms/auth_form.go2
-rw-r--r--services/forms/org.go2
-rw-r--r--services/forms/package_form.go2
-rw-r--r--services/forms/repo_branch_form.go2
-rw-r--r--services/forms/repo_form.go2
-rw-r--r--services/forms/repo_tag_form.go2
-rw-r--r--services/forms/runner.go2
-rw-r--r--services/forms/user_form.go2
-rw-r--r--services/forms/user_form_auth_openid.go2
-rw-r--r--services/webhook/discord.go2
-rw-r--r--services/webhook/slack.go2
-rw-r--r--services/webhook/sourcehut/builds.go2
13 files changed, 13 insertions, 13 deletions
diff --git a/services/forms/admin.go b/services/forms/admin.go
index d71fc076fc..1f055cff55 100644
--- a/services/forms/admin.go
+++ b/services/forms/admin.go
@@ -10,7 +10,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// AdminCreateUserForm form for admin to create user
diff --git a/services/forms/auth_form.go b/services/forms/auth_form.go
index a3eca9473b..f0da63155a 100644
--- a/services/forms/auth_form.go
+++ b/services/forms/auth_form.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// AuthenticationForm form for authentication
diff --git a/services/forms/org.go b/services/forms/org.go
index db182f7e96..dea2e159e9 100644
--- a/services/forms/org.go
+++ b/services/forms/org.go
@@ -11,7 +11,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// ________ .__ __ .__
diff --git a/services/forms/package_form.go b/services/forms/package_form.go
index 9b6f907164..d475d2f569 100644
--- a/services/forms/package_form.go
+++ b/services/forms/package_form.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
type PackageCleanupRuleForm struct {
diff --git a/services/forms/repo_branch_form.go b/services/forms/repo_branch_form.go
index 42e6c85c37..186a4ad367 100644
--- a/services/forms/repo_branch_form.go
+++ b/services/forms/repo_branch_form.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// NewBranchForm form for creating a new branch
diff --git a/services/forms/repo_form.go b/services/forms/repo_form.go
index c3d9c3edc9..63049284d0 100644
--- a/services/forms/repo_form.go
+++ b/services/forms/repo_form.go
@@ -21,7 +21,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// CreateRepoForm form for creating repository
diff --git a/services/forms/repo_tag_form.go b/services/forms/repo_tag_form.go
index 0135684737..38f5996db3 100644
--- a/services/forms/repo_tag_form.go
+++ b/services/forms/repo_tag_form.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// ProtectTagForm form for changing protected tag settings
diff --git a/services/forms/runner.go b/services/forms/runner.go
index 6abfc66fc2..f933750858 100644
--- a/services/forms/runner.go
+++ b/services/forms/runner.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// EditRunnerForm form for admin to create runner
diff --git a/services/forms/user_form.go b/services/forms/user_form.go
index 67c8f00715..afd3a42982 100644
--- a/services/forms/user_form.go
+++ b/services/forms/user_form.go
@@ -16,7 +16,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// InstallForm form for installation page
diff --git a/services/forms/user_form_auth_openid.go b/services/forms/user_form_auth_openid.go
index 595bfecad9..c5ab703fa1 100644
--- a/services/forms/user_form_auth_openid.go
+++ b/services/forms/user_form_auth_openid.go
@@ -9,7 +9,7 @@ import (
"code.gitea.io/gitea/modules/web/middleware"
"code.gitea.io/gitea/services/context"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
// SignInOpenIDForm form for signing in with OpenID
diff --git a/services/webhook/discord.go b/services/webhook/discord.go
index b0142b8509..7741ceb10d 100644
--- a/services/webhook/discord.go
+++ b/services/webhook/discord.go
@@ -26,7 +26,7 @@ import (
"code.gitea.io/gitea/services/forms"
"code.gitea.io/gitea/services/webhook/shared"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
type discordHandler struct{}
diff --git a/services/webhook/slack.go b/services/webhook/slack.go
index af93976bd6..1fa33444f3 100644
--- a/services/webhook/slack.go
+++ b/services/webhook/slack.go
@@ -22,7 +22,7 @@ import (
"code.gitea.io/gitea/services/forms"
"code.gitea.io/gitea/services/webhook/shared"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
)
type slackHandler struct{}
diff --git a/services/webhook/sourcehut/builds.go b/services/webhook/sourcehut/builds.go
index 7b7ace15bb..5a34503a7d 100644
--- a/services/webhook/sourcehut/builds.go
+++ b/services/webhook/sourcehut/builds.go
@@ -24,7 +24,7 @@ import (
"code.gitea.io/gitea/services/forms"
"code.gitea.io/gitea/services/webhook/shared"
- "gitea.com/go-chi/binding"
+ "code.forgejo.org/go-chi/binding"
"gopkg.in/yaml.v3"
)