summaryrefslogtreecommitdiffstats
path: root/src/sp-root.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sp-root.cpp')
-rw-r--r--src/sp-root.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/sp-root.cpp b/src/sp-root.cpp
index c032654ff..e73e83a7f 100644
--- a/src/sp-root.cpp
+++ b/src/sp-root.cpp
@@ -146,7 +146,8 @@ sp_root_build(SPObject *object, SPDocument *document, Inkscape::XML::Node *repr)
SPGroup *group = (SPGroup *) object;
SPRoot *root = (SPRoot *) object;
- if ( !object->repr->attribute("version") ) {
+ //XML Tree being used directly here while it shouldn't be.
+ if ( !object->getRepr()->attribute("version") ) {
repr->setAttribute("version", SVG_VERSION);
}