diff options
author | Vidhu Kant Sharma <vidhukant@vidhukant.xyz> | 2023-01-29 20:47:31 +0530 |
---|---|---|
committer | Vidhu Kant Sharma <vidhukant@vidhukant.xyz> | 2023-01-29 20:47:31 +0530 |
commit | bbc25e292b2561ea38c4ae47bcf379a340980705 (patch) | |
tree | 34eee2ca6032c1f3ecb075003f0638f118cd71d7 | |
parent | 68629768cbb7c86fd4b118e7d555450297f3fb8a (diff) |
added auth middleware to /item
-rw-r--r-- | item/router.go | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/item/router.go b/item/router.go index 614e7f2..a04607c 100644 --- a/item/router.go +++ b/item/router.go @@ -18,13 +18,12 @@ package item import ( - //"github.com/MikunoNaka/OpenBills-server/util" + "github.com/MikunoNaka/OpenBills-server/util" "github.com/gin-gonic/gin" ) func Routes(route *gin.Engine) { - i := route.Group("/item") - //i.Use(util.Authorize()) + i := route.Group("/item", util.Authorize()) { i.GET("/all", getAll) // TODO: add functionality to filter results i.POST("/new", save) |