Skip to content

Commit

Permalink
2.1.5
Browse files Browse the repository at this point in the history
  • Loading branch information
jdmnd committed May 3, 2017
1 parent 08120f2 commit cb555db
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 9 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Expand Up @@ -18,6 +18,7 @@ script:
- npm run reporter
- npm run e2e
- npm run specs
- npm run build

after_script: "cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js"

Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
@@ -1,3 +1,9 @@
## [2.1.5] - 2017-05-03

### Bug Fixes
- Calling login() with a callback (but no auth data) now behaves as you would expect.
- Fix issue where client did not emit `MAX_RECONNECTION_ATTEMPTS_REACHED` event by [@rbarroetavena](@rbarroetavena).

## [2.1.4] - 2017-04-11

### Enhancements
Expand Down
12 changes: 10 additions & 2 deletions dist/deepstream.js
Expand Up @@ -358,6 +358,10 @@ process.off = noop;
process.removeListener = noop;
process.removeAllListeners = noop;
process.emit = noop;
process.prependListener = noop;
process.prependOnceListener = noop;

process.listeners = function (name) { return [] }

process.binding = function (name) {
throw new Error('process.binding is not supported');
Expand Down Expand Up @@ -1916,8 +1920,12 @@ Emitter(Client.prototype); // eslint-disable-line
* @public
* @returns {Client}
*/
Client.prototype.login = function (authParams, callback) {
this._connection.authenticate(authParams || {}, callback);
Client.prototype.login = function (authParamsOrCallback, callback) {
if (typeof authParamsOrCallback === 'function') {
this._connection.authenticate({}, authParamsOrCallback);
} else {
this._connection.authenticate(authParamsOrCallback || {}, callback);
}
return this;
};

Expand Down
6 changes: 3 additions & 3 deletions dist/deepstream.min.js

Large diffs are not rendered by default.

8 changes: 6 additions & 2 deletions dist/lib/client.js
Expand Up @@ -76,8 +76,12 @@ Emitter(Client.prototype); // eslint-disable-line
* @public
* @returns {Client}
*/
Client.prototype.login = function (authParams, callback) {
this._connection.authenticate(authParams || {}, callback);
Client.prototype.login = function (authParamsOrCallback, callback) {
if (typeof authParamsOrCallback === 'function') {
this._connection.authenticate({}, authParamsOrCallback);
} else {
this._connection.authenticate(authParamsOrCallback || {}, callback);
}
return this;
};

Expand Down
12 changes: 10 additions & 2 deletions package.json
@@ -1,6 +1,6 @@
{
"name": "deepstream.io-client-js",
"version": "2.1.4",
"version": "2.1.5",
"description": "the javascript client for deepstream.io",
"main": "dist/lib/client.js",
"types": "src/client.d.ts",
Expand All @@ -26,7 +26,7 @@
"login-e2e": "npm run e2e -- --tags @login",
"presence-e2e": "npm run e2e -- --tags @presence",
"specs": "node ./node_modules/cucumber/bin/cucumber.js test-specs --require ./test-specs/steps",
"build": "babel src -d dist/lib --presets es2015 && grunt build"
"build": "./node_modules/.bin/babel src -d dist/lib --presets es2015 && ./node_modules/.bin/grunt build"
},
"repository": {
"type": "git",
Expand All @@ -47,12 +47,20 @@
"ws": false
},
"devDependencies": {
"babel-cli": "^6.24.1",
"grunt": "^1.0.1",
"babel-preset-es2015": "^6.24.1",
"babelify": "^7.3.0",
"coveralls": "^2.11.16",
"cucumber": "^1.3.1",
"deepstream.io": "git+https://github.com/deepstreamIO/deepstream.io.git",
"deepstream.io-cache-redis": "latest",
"deepstream.io-msg-redis": "latest",
"derequire": "^2.0.6",
"eslint-config-deepstream": "^2.1.1",
"grunt-browserify": "^5.0.0",
"grunt-cli": "^1.2.0",
"grunt-contrib-uglify": "^2.3.0",
"husky": "^0.13.2",
"istanbul": "^0.4.5",
"jasmine": "^2.5.3",
Expand Down

0 comments on commit cb555db

Please sign in to comment.