Skip to content

Inventory Commands fail to load folders unless cache explicitly ignored #65

Description

@KsaRedFx

The Inventory Cache does not cache folders, at all

Currently the saveCache method saves;

        const json = {
            version: this.version,
            items: this.items
        };

While inversely, the loadCache method only looks at this.items

However, folders are under this.folders and when loading the inventory via

const inv = bot.clientCommands.inventory.getInventoryRoot();
inv = inv.populate();

You end up with a inv.folders of [] instead of the array of folders you'd expect, so you're basically forced to not use the cache at all if you want your inventory to be usable in any way

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions