diff --git a/widgets/svgwidget.cpp b/widgets/svgwidget.cpp index 72f381b4a..90cf670ad 100644 --- a/widgets/svgwidget.cpp +++ b/widgets/svgwidget.cpp @@ -77,7 +77,9 @@ Svg *SvgWidget::svg() const void SvgWidget::setElementID(const QString &elementID) { - d->svg->setContainsMultipleImages(!elementID.isNull()); + if (d->svg) { + d->svg->setContainsMultipleImages(!elementID.isNull()); + } d->elementID = elementID; update(); }