@@ -169,16 +169,19 @@ Item {
169169
170170 Item {
171171 id: attributesModel
172− property int numOfAttributes: {
172+ property int numOfAttributes: 0
173+ property var model: []
174+ property bool hasAttributes: {
173175 var attributes = components["attributes"];
174− if ((attributes != undefined) && attributes["field"]) {
176+ var hasAttributesFlag = (attributes != undefined) && attributes["field"];
177+
178+ if (hasAttributesFlag) {
175179 if (attributes["max-count"]) {
176− return attributes["max-count"];
180+ numOfAttributes = attributes["max-count"];
177181 }
178182 }
179− return 0;
183+ return hasAttributesFlag
180184 }
181− property var model: []
182185
183186 onNumOfAttributesChanged: {
184187 model = []