From ce49fec8d844465b00003f5f90b1b9645489a1ff Mon Sep 17 00:00:00 2001 From: Razzmatazz Date: Tue, 28 Jun 2022 22:50:25 -0500 Subject: [PATCH] fix typo --- datasources/items.js | 2 +- schema.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/datasources/items.js b/datasources/items.js index 571d1eea..562cfed4 100644 --- a/datasources/items.js +++ b/datasources/items.js @@ -317,7 +317,7 @@ class ItemsAPI extends WorkerKV { async getTopCategory(id) { await this.init(); const cat = await this.getCategory(id); - if (cat.parent_id) return this.getTopCategory(cat.parent_id); + if (cat && cat.parent_id) return this.getTopCategory(cat.parent_id); return cat; } diff --git a/schema.js b/schema.js index 7fdb5f4f..d2bedd88 100644 --- a/schema.js +++ b/schema.js @@ -185,7 +185,7 @@ type Item { buyFor: [ItemPrice!] containsItems: [ContainedItem] category: ItemCategory - categoryTop: ItemCategory. + categoryTop: ItemCategory bsgCategoryId: String weight: Float velocity: Float