Closed bhollis closed 3 years ago
So digging into the item definitions on https://data.destinysets.com the only item definitions that dont have itemTypeDisplayName are the classified ones. To have a look use the following query in the console
window.$DestinyInventoryItemDefinition.filter(i => i.itemTypeDisplayName === undefined);
That being the case I am going to make that part of the filter. I could be persuaded to have a falsey check on on the name and have "Other" in the event we get some mods that come through on the API that have this missing.
Side note, being as though that can be undefined, should we update the bungie generated API to possibly be undefined?
Edit: The following is probably a more accurate check but gives the same results
window.$DestinyInventoryItemDefinition.filter(i => typeof i.itemTypeDisplayName !== 'string');
Side note, being as though that can be undefined, should we update the bungie generated API to possibly be undefined?
classified items defy all advertised definition structure, so really any work around item defs needs to filter out classified stuff. typing ItemDefinition truly accurately would mean every operation is full of property existence checks
https://twitter.com/dennisk04296487/status/1357522536523837440