dxa-web-application-java icon indicating copy to clipboard operation
dxa-web-application-java copied to clipboard

Nullpointer exception when using SVG images in MultimediaComponent

Open svengabr opened this issue 7 years ago • 0 comments

I have created a new MultimediaComponent and uploaded a SVG image to it. When using this MultimediaComponent in a Component and publish it to my page, the image wont be displayed.

The nullpointer happens in the image resize function at int sourceW = originalImage.getWidth();

Width and height of a SVG image are not filled because it has no defined width and height - its scale-able. Therefor it cant be resized.

svengabr avatar Jul 31 '17 12:07 svengabr