Skip to content

Commit

Permalink
chore: v3.0.0-beta.27
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillaume Chau committed Jan 9, 2019
1 parent 01e7920 commit e53babf
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 10 deletions.
15 changes: 11 additions & 4 deletions dist/vue-apollo.esm.js
Original file line number Diff line number Diff line change
Expand Up @@ -770,10 +770,17 @@ function (_SmartApollo) {
}, {
key: "executeApollo",
value: function executeApollo(variables) {
var variablesJson = JSON.stringify(variables);

if (this.sub) {
if (variablesJson === this.previousVariablesJson) {
return;
}

this.sub.unsubscribe();
} // Create observer
}

this.previousVariablesJson = variablesJson; // Create observer

this.observer = this.vm.$apollo.watchQuery(this.generateApolloOptions(variables));
this.startQuerySubscription();
Expand Down Expand Up @@ -841,7 +848,7 @@ function (_SmartApollo) {
}

if (hasResultCallback) {
this.options.result.call(this.vm, result);
this.options.result.call(this.vm, result, this.key);
}
}
}, {
Expand Down Expand Up @@ -1105,7 +1112,7 @@ function (_SmartApollo) {
_get(_getPrototypeOf(SmartSubscription.prototype), "nextResult", this).call(this, data);

if (typeof this.options.result === 'function') {
this.options.result.call(this.vm, data);
this.options.result.call(this.vm, data, this.key);
}
}
}]);
Expand Down Expand Up @@ -1918,7 +1925,7 @@ function install(Vue, options) {
}
ApolloProvider.install = install; // eslint-disable-next-line no-undef

ApolloProvider.version = "3.0.0-beta.26"; // Apollo provider
ApolloProvider.version = "3.0.0-beta.27"; // Apollo provider

var ApolloProvider$1 = ApolloProvider; // Components

Expand Down
Loading

0 comments on commit e53babf

Please sign in to comment.