Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
lunny committed Feb 5, 2021
1 parent 6876c9b commit 4c7c494
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions routers/api/v1/admin/hooks.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

package org
package admin

import (
"net/http"
Expand Down Expand Up @@ -36,7 +36,7 @@ func ListHooks(ctx *context.APIContext) {
// "200":
// "$ref": "#/responses/HookList"

sysHooks, err := models.GetSystemWebhooks(utils.GetListOptions(ctx))
sysHooks, err := models.GetSystemWebhooks()
if err != nil {
ctx.Error(http.StatusInternalServerError, "GetSystemWebhooks", err)
return
Expand Down
2 changes: 1 addition & 1 deletion routers/api/v1/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -1032,7 +1032,7 @@ func Routes() *web.Route {
m.Combo("").Get(admin.ListHooks).
Post(bind(api.CreateHookOption{}), admin.CreateHook)
m.Combo("/{id}").Get(admin.GetHook).
Patch(bind(admin.EditHookOption{}), admin.EditHook).
Patch(bind(api.EditHookOption{}), admin.EditHook).
Delete(admin.DeleteHook)
})
}, reqToken(), reqSiteAdmin())
Expand Down

0 comments on commit 4c7c494

Please sign in to comment.