Replaces icon with image

This commit is contained in:
freearhey committed 2024-06-24 16:49:35 +03:00
1 parent 0eaff54a31
commit bb6771f539
170 files changed
+428 -351

No files matched your search

+2 -2
View File
@@ -45,7 +45,7 @@ module.exports = {
title: item.name,
category: item.genres,
description: item.introduce,
icon: parseIcon(item),
image: parseImage(item),
start: start.toJSON(),
stop: stop.toJSON()
})
@@ -79,7 +79,7 @@ module.exports = {
}
}
function parseIcon(item) {
function parseImage(item) {
return item.pictures && item.pictures.length ? item.pictures[0].href : null
}
+2 -1
View File
@@ -35,7 +35,8 @@ it('can parse response', () => {
stop: '2021-11-07T01:00:00.000Z',
title: '24 Portre',
category: 'Yaşam',
icon: 'https://izmottvsc23.tvplus.com.tr:33207/CPS/images/universal/film/program/202111/20211104/35/20211104000026695lh5.jpg',
image:
'https://izmottvsc23.tvplus.com.tr:33207/CPS/images/universal/film/program/202111/20211104/35/20211104000026695lh5.jpg',
description:
'Kendi alanında büyük başarılar elde etmiş insanların kendi ağzından hayat hikayeleri ekrana geliyor.'
}