Merge pull request 'dev_id can null for internal towers' (#26) from feature/responses-v2 into dev
Reviewed-on: winter-access/backend_nam#26
This commit is contained in:
commit
a601ec7996
|
|
@ -45,10 +45,6 @@ func (u *towerUsecase) PostWithMultipleImages(tower req.TowerDTO, imageFiles []*
|
|||
return err
|
||||
}
|
||||
|
||||
// Validate that if it's not an external tower, DeviceID must be provided
|
||||
if tower.ExternalTower != nil && !*tower.ExternalTower && tower.DeviceID == nil {
|
||||
return fmt.Errorf("device_id is required for internal towers")
|
||||
}
|
||||
|
||||
// Validate that if DeviceID is provided, the device exists
|
||||
if tower.DeviceID != nil {
|
||||
|
|
|
|||
Loading…
Reference in New Issue