mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-10-29 23:12:39 +01:00
Fixed: Series Network filter breaking if network was not available
This commit is contained in:
parent
00821b7ad6
commit
618c611a59
@ -298,12 +298,16 @@ export const defaultState = {
|
||||
label: 'Network',
|
||||
type: filterBuilderTypes.STRING,
|
||||
optionsSelector: function(items) {
|
||||
const tagList = items.map((series) => {
|
||||
return {
|
||||
id: series.network,
|
||||
name: series.network
|
||||
};
|
||||
});
|
||||
const tagList = items.reduce((acc, series) => {
|
||||
if (series.network) {
|
||||
acc.push({
|
||||
id: series.network,
|
||||
name: series.network
|
||||
});
|
||||
}
|
||||
|
||||
return acc;
|
||||
}, []);
|
||||
|
||||
return tagList.sort(sortByName);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user