Closed
Description
Take this Parse server example:
// op=subscribe, className=Message, roomName=null, requestId=1, order=createdAt
ParseQuery<Message> parseQuery = ParseQuery.getQuery(Message.class);
parseQuery.whereEqualTo("roomName", "test");
parseQuery.orderByAscending("createdAt");
The same query in Swift doesn't cause this issue. The issue is we serialize orderByAscending for ParseQueries, which gets passed along to the subscription request.
var messagesQuery: PFQuery<Message> {
return (Message.query()?
.whereKey("roomName", equalTo: currentChatRoom!.name!)
.order(byAscending: "createdAt")) as! PFQuery<Message>
}
There are some issues if you have a ParseQuery that uses order by semantics (see #14).
I think we may need our own Parse encoding/decoding as it's done in the iOS version (https://github.com/ParsePlatform/ParseLiveQuery-iOS-OSX/blob/master/Sources/ParseLiveQuery/Internal/QueryEncoder.swift)
Metadata
Metadata
Assignees
Labels
No labels