=== modified file 'src/Ubuntu/Components/plugin/sortfiltermodel.cpp'
--- src/Ubuntu/Components/plugin/sortfiltermodel.cpp	2015-03-03 13:47:48 +0000
+++ src/Ubuntu/Components/plugin/sortfiltermodel.cpp	2015-08-20 17:10:36 +0000
@@ -113,9 +113,12 @@
 QSortFilterProxyModelQML::roleByName(const QString& roleName) const
 {
     const QHash<int, QByteArray> roles = roleNames();
-    for(int role = 0; role < roles.count(); role++)
-        if (roles[role] == roleName)
-            return role;
+    QHashIterator<int, QByteArray> i(roles);
+    while (i.hasNext()) {
+        i.next();
+        if (i.value() == roleName)
+            return i.key();
+    }
     return 0;
 }
 

