Skip to content

Commit

Permalink
Improved: Returned list of good identifications directly while fetchi…
Browse files Browse the repository at this point in the history
…ng (#91).
  • Loading branch information
ravilodhi committed Oct 24, 2024
1 parent 6280fc9 commit e6bed48
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/modules/product/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -183,9 +183,9 @@ async function fetchGoodIdentificationTypes(parentTypeId: string = "HC_GOOD_ID_T
}) as any

if (!hasError(resp)) {
return Promise.resolve(resp.data)
return Promise.resolve(resp.data.docs)
} else {
throw resp.data.docs;
throw resp.data;
}
} catch (err) {
return Promise.reject({
Expand Down

0 comments on commit e6bed48

Please sign in to comment.