File tree Expand file tree Collapse file tree 1 file changed +1
-12
lines changed
Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -26,18 +26,7 @@ func (ah AuthHandler) Authenticate(c *fiber.Ctx) error {
2626 "message" : err .Error (),
2727 })
2828 }
29- if body .ConnectionToken != "" && body .Password != "" {
30- log .Errorf ("Authenticate: You have to connect with only one of the following methods: connection token / password" )
31- return c .Status (fiber .StatusInternalServerError ).JSON (fiber.Map {
32- "message" : "You have to connect with only one of the following methods: connection token / password" ,
33- })
34- }
35- if body .ConnectionToken == "" && body .Password == "" {
36- log .Errorf ("Authenticate: You have to connect with one of the following methods: connection token / password" )
37- return c .Status (fiber .StatusInternalServerError ).JSON (fiber.Map {
38- "message" : "You have to connect with one of the following methods: connection token / password" ,
39- })
40- }
29+
4130 if err := utils .Validate (body ); err != nil {
4231 return c .Status (400 ).JSON (fiber.Map {
4332 "message" : err ,
You can’t perform that action at this time.
0 commit comments