Skip to content

Commit

Permalink
fix(filters): using invalid field for networks and studios #721
Browse files Browse the repository at this point in the history
  • Loading branch information
ADRFranklin committed Aug 17, 2022
1 parent 27382d6 commit 3fedb44
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pkg/api/src/requests/filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,18 +125,18 @@ function getValue(condition, media) {
break;
case "network":
values = [];
if (media.networks && Array.isArray(media.networks.results))
media.networks.results.map((nw) => {
if (media.networks && Array.isArray(media.networks))
media.networks.map((nw) => {
values.push(nw.name);
});
break;
case "studio":
values = [];
if (
media.production_companies &&
Array.isArray(media.production_companies.results)
Array.isArray(media.production_companies)
)
media.production_companies.results.map((cp) => {
media.production_companies.map((cp) => {
values.push(cp.name);
});
break;
Expand Down

0 comments on commit 3fedb44

Please sign in to comment.