Skip to content

Null/Empty Key Handling #3

@Yortw

Description

@Yortw

Just noticed while browsing the source that the Klout class allows construction with a null or blank key, but will then throw an KloutException when any of the methods are called. It also appears the only way to set the key is via the constructor, so you can't fix the problem after the instance is created.

Have I missed something? While it would be a breaking change at this point, would it not be better to throw an Argument or ArgumentNull exception from the constructor on an invalid key, rather than throwing a KloutException sometime later when it's all too late anyway?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions