1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

If item EndYear is the same as ProductionYear only display ProductionYear

This commit is contained in:
Mariusz Chryc 2019-12-19 21:23:26 +01:00
parent 4f71cc1814
commit d111e8cf4d

View file

@ -892,7 +892,8 @@ define(['datetime', 'imageLoader', 'connectionManager', 'itemHelper', 'focusMana
} else { } else {
if (item.EndDate && item.ProductionYear) { if (item.EndDate && item.ProductionYear) {
lines.push(item.ProductionYear + ' - ' + datetime.parseISO8601Date(item.EndDate).getFullYear()); var endYear = datetime.parseISO8601Date(item.EndDate).getFullYear();
lines.push(item.ProductionYear + (endYear === item.ProductionYear) ? '' : (' - ' + endYear));
} else { } else {
lines.push(item.ProductionYear || ''); lines.push(item.ProductionYear || '');
} }