implement and test forget and reset nkode
This commit is contained in:
@@ -39,11 +39,13 @@ func (h *NkodeHandler) RegisterRoutes(r *gin.Engine) {
|
||||
r.POST("/refresh-token", h.RefreshTokenHandler)
|
||||
r.POST("/forgot-nkode", h.ForgotNKodeHandler)
|
||||
r.POST("/signout", h.SignoutHandler)
|
||||
r.POST("/reset", h.ResetHandler)
|
||||
r.POST("/reset-nkode", h.ResetHandler)
|
||||
}
|
||||
}
|
||||
|
||||
func (h *NkodeHandler) CreateNewCustomerHandler(c *gin.Context) {
|
||||
h.Logger.Println("create new customer")
|
||||
|
||||
var newCustomerPost entities.NKodePolicy
|
||||
if err := c.ShouldBind(&newCustomerPost); err != nil {
|
||||
handleError(c, err)
|
||||
@@ -217,7 +219,7 @@ func (h *NkodeHandler) RenewAttributesHandler(c *gin.Context) {
|
||||
return
|
||||
}
|
||||
|
||||
if err := h.API.RenewAttributes(entities.CustomerId(customerId)); err != nil {
|
||||
if err = h.API.RenewAttributes(entities.CustomerId(customerId)); err != nil {
|
||||
handleError(c, err)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user