@@ -169,19 +169,16 @@ Item {
169169
170170 Item {
171171 id: attributesModel
172− property int numOfAttributes: 0
173− property var model: []
174− property bool hasAttributes: {
172+ property int numOfAttributes: {
175173 var attributes = components["attributes"];
176− var hasAttributesFlag = (attributes != undefined) && attributes["field"];
177−
178− if (hasAttributesFlag) {
174+ if ((attributes != undefined) && attributes["field"]) {
179175 if (attributes["max-count"]) {
180− numOfAttributes = attributes["max-count"];
176+ return attributes["max-count"];
181177 }
182178 }
183− return hasAttributesFlag
179+ return 0;
184180 }
181+ property var model: []
185182
186183 onNumOfAttributesChanged: {
187184 model = []