Skip to content

Commit

Permalink
PR fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Duncalf committed May 25, 2022
1 parent c2cfc0d commit fb7983e
Show file tree
Hide file tree
Showing 3 changed files with 1,859 additions and 649 deletions.
2 changes: 1 addition & 1 deletion lib/extensions.js
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ module.exports = function (realmConstructor) {
getOwnPropertyDescriptors(mutableSubscriptionSetMethods.static),
);
Object.defineProperties(realmConstructor.App.Sync.MutableSubscriptionSet.prototype, {
...getOwnPropertyDescriptors(mutableSubscriptionSetMethods.instance(realmConstructor)),
...getOwnPropertyDescriptors(mutableSubscriptionSetMethods.instance),
});

let sessionMethods = require("./session");
Expand Down
10 changes: 5 additions & 5 deletions lib/mutable-subscription-set.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ const { symbols } = require("@realm.io/common");
//
// Once our v11 branch is merged, we can revert this change as JSI React Native `Proxy`s
// work fine, by reverting PR #4541.
const instanceMethods = (realmConstructor) => ({
const instanceMethods = {
add(query, options) {
return this._add(query[symbols.REALM_REACT_PROXIED_OBJECT] || query, options);
return this._add(query[symbols.PROXY_TARGET] || query, options);
},

remove(query) {
return this._remove(query[symbols.REALM_REACT_PROXIED_OBJECT] || query);
}
});
return this._remove(query[symbols.PROXY_TARGET] || query);
},
};

const staticMethods = {
// none
Expand Down
Loading

0 comments on commit fb7983e

Please sign in to comment.