Fix tags saving as empty object/Set

This commit is contained in:
Sam Carlton 2021-04-24 15:09:48 -05:00
parent 41c0457fcd
commit f53e81eb8e

View file

@ -107,7 +107,7 @@ async function fetchBundleGenres () {
}
function generateTagsFromGenres( bundleId, bundleGenres ) {
function generateTagsSetFromGenres( bundleId, bundleGenres ) {
// If we don't have this bundleID
// then return empty
if ( !bundleGenres.has( bundleId ) ) return []
@ -186,7 +186,7 @@ export default async function () {
// console.log('appScan', appScan)
const tags = generateTagsFromGenres( appScan.bundleIdentifier, bundleGenres )
const tags = generateTagsSetFromGenres( appScan.bundleIdentifier, bundleGenres )
// Add to scanned app list
scanListMap.set( appSlug, {
@ -207,7 +207,7 @@ export default async function () {
category: {
slug: 'uncategorized'
},
tags,
tags: Array.from(tags),
relatedLinks
})
})