mirror of
https://github.com/Alvin-Zilverstand/nginx-proxy-manager.git
synced 2026-11-28 00:47:54 +01:00
New lint rules
This commit is contained in:
85 files changed
+385
-259
No files matched your search
@@ -151,7 +151,7 @@ func getCertificateFromRequest(w http.ResponseWriter, r *http.Request) *certific
|
||||
|
||||
// fillObjectFromBody has some reusable code for all endpoints that
|
||||
// have a certificate id in the url. it will write errors to the output.
|
||||
func fillObjectFromBody(w http.ResponseWriter, r *http.Request, validationSchema string, o interface{}) bool {
|
||||
func fillObjectFromBody(w http.ResponseWriter, r *http.Request, validationSchema string, o any) bool {
|
||||
bodyBytes, _ := r.Context().Value(c.BodyCtxKey).([]byte)
|
||||
|
||||
if validationSchema != "" {
|
||||
@@ -176,10 +176,10 @@ func fillObjectFromBody(w http.ResponseWriter, r *http.Request, validationSchema
|
||||
return true
|
||||
}
|
||||
|
||||
func configureCertificate(c certificate.Model) {
|
||||
func configureCertificate(cert certificate.Model) {
|
||||
err := jobqueue.AddJob(jobqueue.Job{
|
||||
Name: "RequestCertificate",
|
||||
Action: c.Request,
|
||||
Action: cert.Request,
|
||||
})
|
||||
if err != nil {
|
||||
logger.Error("ConfigureCertificateError", err)
|
||||
|
||||
Reference in new issue
Block a user