Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

empty numbers parsed as NaN values create issues in where data should be immutable #14

Open
mbarto opened this issue Dec 14, 2017 · 1 comment

Comments

@mbarto
Copy link

mbarto commented Dec 14, 2017

Currently empty numbers are parsed as NaN values by parseDBF.
Since NaN !== NaN, if I compare two such values I always get they are not equal.
Could it be possible to parse those values as undefined or null?

e.g.

switch (type) {
    case 'N':
    case 'F':
    case 'O':
      return parseFloat(textData, 10) || undefined;
@calvinmetcalf
Copy link
Owner

hm yeah that code doesn't do what its intending to do

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants