Skip to content
This repository was archived by the owner on Jan 26, 2021. It is now read-only.

Commit 75cbb40

Browse files
committed
Allow equalTo queries with Parse.Object pointers
1 parent 3897b90 commit 75cbb40

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/QueryTools.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,9 +190,10 @@ function matchesKeyConstraints(object, key, constraints) {
190190
var compareTo;
191191
if (constraints.__type) {
192192
if (constraints.__type === 'Pointer') {
193+
var objectId = object[key].objectId || object[key].id;
193194
return (
194195
constraints.className === object[key].className &&
195-
constraints.objectId === object[key].objectId
196+
constraints.objectId === objectId
196197
);
197198
}
198199
compareTo = Parse._decode(key, constraints);

0 commit comments

Comments
 (0)