mirror of
https://github.com/1f349/orchid.git
synced 2024-11-09 23:02:53 +00:00
Add missing parameter in checkAuthForCertificate
This commit is contained in:
parent
2f5e74d3f4
commit
04551ec3bb
@ -55,7 +55,7 @@ func checkAuthWithPerm(verify mjwt.Verifier, perm string, cb AuthCallback) httpr
|
|||||||
func checkAuthForCertificate(verify mjwt.Verifier, perm string, db *sql.DB, cb CertAuthCallback) httprouter.Handle {
|
func checkAuthForCertificate(verify mjwt.Verifier, perm string, db *sql.DB, cb CertAuthCallback) httprouter.Handle {
|
||||||
return checkAuthWithPerm(verify, perm, func(rw http.ResponseWriter, req *http.Request, params httprouter.Params, b AuthClaims) {
|
return checkAuthWithPerm(verify, perm, func(rw http.ResponseWriter, req *http.Request, params httprouter.Params, b AuthClaims) {
|
||||||
// lookup certificate owner
|
// lookup certificate owner
|
||||||
id, err := checkCertOwner(db, "", b)
|
id, err := checkCertOwner(db, params.ByName("id"), b)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
apiError(rw, http.StatusInsufficientStorage, "Database error")
|
apiError(rw, http.StatusInsufficientStorage, "Database error")
|
||||||
return
|
return
|
||||||
|
Loading…
Reference in New Issue
Block a user