Not a JPEG file: starts with 0x89 0x50

Trying to parse a jpg image I found that my console was throwing this error: "Not a JPEG file: starts with 0x89 0x50"

I did not understand why?, then I found that:

The file was actually a PNG with the wrong file extension. "0x89 0x50" is how a PNG file starts.

So I did not notice that the image was wrong named.

That's all folks, nothing more to see here!, follow me on @zazvick

Victor Velazquez

Coder, Musician, Startups, Passionate Dancer & Life Lover. Director of Engineering at MagmaLabs, Co-founder of Web Dev Talks, Co-founder of Voltaire, Co-founder of Paqkit, Ex-co-founder of Zaznova.

Subscribe to The zazvick's blog

Get the latest posts delivered right to your inbox.

or subscribe via RSS with Feedly!