Skip to content

User-friendly message for token validation error #30

@d4n3436

Description

@d4n3436

When an invalid token is passed to DiscordHostConfiguration on ConfigureDiscordShardedHost() and ConfigureDiscordHost(), an OptionsValidationException exception is thrown with message: "A validation error has occurred.".

This message, however, doesn't doesn't explain what went wrong or what's the root cause of the issue.
I suggest adding a custom, user-friendly message like "An empty or invalid token was provided." on the Validate method.
This will make debugging and troubleshooting easier.

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