ES5 → 7: Use enhanced object properties
http://es6-features.org/#PropertyShorthand Instead of doing {"foo": foo, "bar": bar, ...}, we can just do {foo, bar} now. The function parameters of EventHandlers have all been renamed to camelCase to make use of this, as the JS style conventions intend. Other functions will follow in a later commit.
This commit is contained in:
@@ -64,11 +64,7 @@ Item {
|
||||
}
|
||||
|
||||
function showRoom(userId, category, roomId) {
|
||||
var info = rooms.getWhere({
|
||||
"userId": userId,
|
||||
"roomId": roomId,
|
||||
"category": category
|
||||
}, 1)[0]
|
||||
var info = rooms.getWhere({userId, roomId, category}, 1)[0]
|
||||
|
||||
pageStack.replace("Chat/Chat.qml", {"roomInfo": info})
|
||||
}
|
||||
|
Reference in New Issue
Block a user