Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upBugfix for decodeDataUrl when data contains newlines #983
Conversation
Remove the newlines before doing a Regex check inside the decodeDataUrl method in the same way that is the isBase64 method doing.
Remove the newlines before doing a Regex check inside the
decodeDataUrlmethod in the same way that is theisBase64method doing.Some base64 encoded images contains newlines, passing them directly to the
Image::makemethod can result in aNotReadableException.Here are the tests I did before this commit :