not require UserAgent
This commit is contained in:
parent
43fc966f9a
commit
c67099df03
16
validate.go
16
validate.go
|
@ -16,14 +16,6 @@ func (co CreateOptions) validate() error {
|
|||
return errors.New("no deviceID data")
|
||||
}
|
||||
|
||||
// UserAgent
|
||||
if co.UserAgent == "" {
|
||||
logger.Error("devicemngmt - Create: no userAgent data", logger.LogData{
|
||||
"payload": co,
|
||||
})
|
||||
return errors.New("no userAgent data")
|
||||
}
|
||||
|
||||
// IP
|
||||
if co.IP == "" {
|
||||
logger.Error("devicemngmt - Create: no ip data", logger.LogData{
|
||||
|
@ -66,14 +58,6 @@ func (uo UpdateOptions) validate() error {
|
|||
return errors.New("invalid userID data")
|
||||
}
|
||||
|
||||
// UserAgent
|
||||
if uo.UserAgent == "" {
|
||||
logger.Error("devicemngmt - Update: no userAgent data", logger.LogData{
|
||||
"payload": uo,
|
||||
})
|
||||
return errors.New("no userAgent data")
|
||||
}
|
||||
|
||||
// IP
|
||||
if uo.IP == "" {
|
||||
logger.Error("devicemngmt - Update: no ip data", logger.LogData{
|
||||
|
|
Loading…
Reference in New Issue