jimp-dev / bmp-ts

A pure typescript bmp encoder and decoder
MIT License
15 stars 6 forks source link

unreachable code #14

Open calumsult opened 3 years ago

calumsult commented 3 years ago

In the scanImage function in the decoder there's this bit:

const result = processPixel.call(this, x, line); if (result === false) { return; }

...but processPixel is defined as returning void, hence the if statement will never evaluate to true. Any idea what was intended with that code? I can submit a pr and fix it, but just glancing at it I'm not sure what the intent was. Thanks!

hipstersmoothie commented 3 years ago

it's been awhile since I've looked at this code. def seems like it could be removed. feel free to make a PR!