Skip to content

Metadata class shouldn't throw NPE for missing keys #69

@gcurtis

Description

@gcurtis

The getID(), getTypeName(), and getParentID() methods can possibly throw a NPE if an empty metadata object is created. Similarly, the get(String) method will throw an exception if a requested key doesn't exist. This is because this.values.get("some-key") returns null and then asString() gets called on it.

These methods should do null checks before calling asString() and return null if the key doesn't exist.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugAdded to issues that describes SDK bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions