@apollo/client 3.11.6 → 3.11.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/cache/cache.cjs CHANGED
@@ -170,7 +170,10 @@ var ApolloCache = (function () {
170
170
  var _this = this;
171
171
  var fragment = options.fragment, fragmentName = options.fragmentName, from = options.from, _a = options.optimistic, optimistic = _a === void 0 ? true : _a, otherOptions = tslib.__rest(options, ["fragment", "fragmentName", "from", "optimistic"]);
172
172
  var query = this.getFragmentDoc(fragment, fragmentName);
173
- var diffOptions = tslib.__assign(tslib.__assign({}, otherOptions), { returnPartialData: true, id: typeof from === "string" ? from : this.identify(from), query: query, optimistic: optimistic });
173
+ var diffOptions = tslib.__assign(tslib.__assign({}, otherOptions), { returnPartialData: true, id:
174
+ typeof from === "undefined" || typeof from === "string" ?
175
+ from
176
+ : this.identify(from), query: query, optimistic: optimistic });
174
177
  var latestDiff;
175
178
  return new utilities.Observable(function (observer) {
176
179
  return _this.watch(tslib.__assign(tslib.__assign({}, diffOptions), { immediate: true, callback: function (diff) {