Skip to content

Commit

Permalink
Remove an old warning about no subscription (#258)
Browse files Browse the repository at this point in the history
  • Loading branch information
kamilkisiela committed Jan 24, 2017
1 parent 8dc2041 commit c6734fb
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
5 changes: 0 additions & 5 deletions src/Angular2Apollo.ts
Expand Up @@ -31,11 +31,6 @@ export class Angular2Apollo {
}

public subscribe(options: SubscriptionOptions): Observable<any> {
// XXX Try to remove it soon
if (typeof this.client.subscribe === 'undefined') {
throw new Error(`Your version of ApolloClient doesn't support subscriptions`);
}

return from(this.client.subscribe(options));
}

Expand Down
8 changes: 0 additions & 8 deletions tests/Angular2Apollo.spec.ts
Expand Up @@ -220,14 +220,6 @@ describe('angular2Apollo', () => {
});

describe('subscribe', () => {
it('should throw an error if method is missing', () => {
client.subscribe = undefined;

expect(() => {
angular2Apollo.subscribe({});
}).toThrowError('subscriptions');
});

it('should be called with the same options and return Observable', (done: jest.DoneCallback) => {
const options = {query: '', variables: {}};

Expand Down

0 comments on commit c6734fb

Please sign in to comment.