write ytmusic stuffs to cache

This commit is contained in:
2026-01-19 14:47:10 -05:00
parent 9ff2252227
commit 227cde48d9
2 changed files with 3 additions and 0 deletions

View File

@@ -88,6 +88,8 @@ async function updateSongs() {
if (typeof playlistSongs == 'object') {
// For each song that youtube moosic has yelled back at us, give them individually to populateThumbnails()
await Promise.all(playlistSongs.map(async song => await populateThumbnails(song)));
// Write all of this to cache
fs.writeFileSync(path.join(baseDir + 'ytmusic_cache'), JSON.stringify({playlistSongs, thumbnails}));
}
else {
// like legit this shouldnt even be possible