diff --git a/config/collections/index.js b/config/collections/index.js index d254046f..bfb1a37a 100644 --- a/config/collections/index.js +++ b/config/collections/index.js @@ -66,7 +66,7 @@ export const processContent = (collection) => { } const movieData = movies['movies'].filter((movie) => movie['rating']) - const showData = tv['shows'].filter((show) => show['last_watched_at']) + const showData = tv['shows'].filter((show) => show['episodes']?.[0]?.['last_watched_at']) const bookData = books.all.filter((book) => book['rating']) const addItemToIndex = (items, icon, getUrl, getTitle, getTags) => { diff --git a/package-lock.json b/package-lock.json index 56b50d14..297763d9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "coryd.dev", - "version": "24.7.13", + "version": "24.7.14", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "coryd.dev", - "version": "24.7.13", + "version": "24.7.14", "license": "MIT", "dependencies": { "@cdransf/api-text": "^1.5.0", @@ -38,7 +38,7 @@ "rimraf": "^6.0.1", "sanitize-html": "^2.13.0", "slugify": "^1.6.6", - "terser": "^5.31.6" + "terser": "^5.32.0" } }, "node_modules/@11ty/dependency-tree": { @@ -731,9 +731,9 @@ } }, "node_modules/acorn-walk": { - "version": "8.3.3", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.3.tgz", - "integrity": "sha512-MxXdReSRhGO7VlFe1bRG/oI7/mdLV9B9JJT0N8vZOhF7gFRR5l3M8W9G8JxmKV+JC5mGqJ0QvqfSOLsCPa4nUw==", + "version": "8.3.4", + "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.4.tgz", + "integrity": "sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==", "dev": true, "license": "MIT", "dependencies": { @@ -1066,9 +1066,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001658", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001658.tgz", - "integrity": "sha512-N2YVqWbJELVdrnsW5p+apoQyYt51aBMSsBZki1XZEfeBCexcM/sf4xiAHcXQBkuOwJBXtWF7aW1sYX6tKebPHw==", + "version": "1.0.30001659", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001659.tgz", + "integrity": "sha512-Qxxyfv3RdHAfJcXelgf0hU4DFUVXBGTjqrBUZLUh8AtlGnsDo+CnncYtTd95+ZKfnANUOzxyIQCuU/UeBZBYoA==", "dev": true, "funding": [ { @@ -4688,9 +4688,9 @@ } }, "node_modules/terser": { - "version": "5.31.6", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz", - "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==", + "version": "5.32.0", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.32.0.tgz", + "integrity": "sha512-v3Gtw3IzpBJ0ugkxEX8U0W6+TnPKRRCWGh1jC/iM/e3Ki5+qvO1L1EAZ56bZasc64aXHwRHNIQEzm6//i5cemQ==", "dev": true, "license": "BSD-2-Clause", "dependencies": { diff --git a/package.json b/package.json index a9f7a252..6da1d981 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "coryd.dev", - "version": "24.7.13", + "version": "24.7.14", "description": "The source for my personal site. Built using 11ty (and other tools).", "type": "module", "scripts": { @@ -54,6 +54,6 @@ "rimraf": "^6.0.1", "sanitize-html": "^2.13.0", "slugify": "^1.6.6", - "terser": "^5.31.6" + "terser": "^5.32.0" } } diff --git a/src/data/tv.js b/src/data/tv.js index 2e8df7f4..b1fa02a8 100644 --- a/src/data/tv.js +++ b/src/data/tv.js @@ -16,7 +16,6 @@ const fetchAllShows = async () => { .select(` id, tmdb_id, - last_watched_at, title, year, collected, @@ -97,9 +96,9 @@ const prepareEpisodeData = (show) => show['episodes'].map(episode => ({ favorite: show['favorite'], image: show['image'], backdrop: show['backdrop'], - episode_number: episode['episode_number'] || 0, - season_number: episode['season_number'] || 0, - last_watched_at: episode['last_watched_at'] || '1970-01-01T00:00:00Z' + episode_number: episode['episode_number'], + season_number: episode['season_number'], + last_watched_at: episode['last_watched_at'] })) const formatEpisodeData = (episodes) => {