node-dbf
node-dbf copied to clipboard
Conversion of Buffer to Number was not correct for some numbers
Hey,
I found this small issue, while the converter was not correct.
Now, it's working perfectly for me.
Header.prototype.convertBinaryToInteger = function (buffer) { if (buffer.length == 1) return buffer.readUInt8(0); if (buffer.length == 2) return buffer.readUInt16LE(0); if (buffer.length == 4) return buffer.readUInt32LE(0); return 0; };
Thanks for your great code!
András