mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Merge pull request #4873 from scampower3/year-fix-mediainfo
Fix duplicate year in the series details page
This commit is contained in:
commit
0dbdc5de96
1 changed files with 3 additions and 3 deletions
|
@ -183,9 +183,9 @@ export function getMediaInfoHtml(item, options = {}) {
|
||||||
if (item.EndDate) {
|
if (item.EndDate) {
|
||||||
try {
|
try {
|
||||||
const endYear = datetime.toLocaleString(datetime.parseISO8601Date(item.EndDate).getFullYear(), { useGrouping: false });
|
const endYear = datetime.toLocaleString(datetime.parseISO8601Date(item.EndDate).getFullYear(), { useGrouping: false });
|
||||||
|
/* At this point, text will contain only the start year */
|
||||||
if (endYear !== item.ProductionYear) {
|
if (endYear !== text) {
|
||||||
text += `-${endYear}`;
|
text += ` - ${endYear}`;
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error('error parsing date:', item.EndDate);
|
console.error('error parsing date:', item.EndDate);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue