jayasurian123 / fen-validator

Validate the Chess FEN notation
10 stars 3 forks source link

Error when submitting non-string arguments to the validation function #22

Closed nlukic97 closed 2 years ago

nlukic97 commented 2 years ago

If an argument that is not of type 'string' is passed to the parseFEN function, this will cause an error when trying to split the fen argument.

nlukic97 commented 2 years ago

I have just created a pull request which should fix this issue: https://github.com/jayasurian123/fen-validator/pull/23

jayasurian123 commented 2 years ago

good catch. If any other type except "string" return false.

jayasurian123 commented 2 years ago

v1.4.2 has the fix you have submitted. thanks.