mirror of
https://github.com/badlogic/heissepreise.git
synced 2024-06-16 05:34:21 +02:00
Penny category mapper fix.
This commit is contained in:
parent
aebeb6d150
commit
6251c06b59
|
@ -82,6 +82,7 @@ exports.initializeCategoryMapping = async () => {
|
|||
|
||||
exports.mapCategory = (rawItem) => {
|
||||
const categoryPath = rawItem.parentCategories.filter((path) => path.length > 0 && !path[0].name.includes("ngebot"))[0];
|
||||
if (!categoryPath) return null;
|
||||
const categoryName = categoryPath.map((path) => path.name).join(" -> ");
|
||||
const category = exports.categoryLookup[categoryName];
|
||||
if (category) return category.code;
|
||||
|
|
Loading…
Reference in New Issue
Block a user