Skip to content

Enhance card-key validation #23

Description

@devinpearson

If a non-numeric value (e.g., "abc") is passed, Number(credentials.cardKey) will yield NaN, potentially leading to runtime issues.

if (!/^\d+$/.test(credentials.cardKey)) { throw new Error("card-key must be a valid numeric string"); } options.cardKey = Number(credentials.cardKey);

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions