mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
Merge branch 'fix/nonstock-undefined-field' into 'development'
fix(be): nonstock response supplier null to empty array See merge request mbugroup/lti-api!120
This commit is contained in:
@@ -101,7 +101,7 @@ func ToNonstockDetailDTO(e entity.Nonstock) NonstockDetailDTO {
|
||||
|
||||
func toNonstockSupplierDTOs(relations []entity.NonstockSupplier) []supplierDTO.SupplierRelationDTO {
|
||||
if len(relations) == 0 {
|
||||
return nil
|
||||
return make([]supplierDTO.SupplierRelationDTO, 0)
|
||||
}
|
||||
|
||||
result := make([]supplierDTO.SupplierRelationDTO, 0, len(relations))
|
||||
@@ -113,7 +113,7 @@ func toNonstockSupplierDTOs(relations []entity.NonstockSupplier) []supplierDTO.S
|
||||
}
|
||||
|
||||
if len(result) == 0 {
|
||||
return nil
|
||||
return make([]supplierDTO.SupplierRelationDTO, 0)
|
||||
}
|
||||
|
||||
return result
|
||||
|
||||
Reference in New Issue
Block a user