mg-api-node
Advanced tools
Comparing version 1.3.0 to 1.3.1
@@ -23,4 +23,4 @@ var https = require('https'); | ||
if (!!sessionId) { | ||
if (!database || directServer === 'my.geotab.com') { | ||
throw new Error('Must supply database and server') | ||
if (!database) { | ||
throw new Error('Must supply database') | ||
} | ||
@@ -27,0 +27,0 @@ |
{ | ||
"name": "mg-api-node", | ||
"version": "1.3.0", | ||
"description": "Unofficial nodejs client for the MyGeotab API", | ||
"version": "1.3.1", | ||
"description": "Nodejs client for the MyGeotab API", | ||
"main": "api.js", | ||
@@ -6,0 +6,0 @@ "devDependencies": { |
@@ -0,0 +0,0 @@ # This project has been deprecated. Please use [mg-api-js](https://github.com/Geotab/mg-api-js). |
@@ -65,15 +65,15 @@ var expect = require('chai').expect; | ||
it('creates API with session id but no database or server', function () { | ||
expect(API.bind(API, userName, null, null, null, null, sessionId)).to.throw('Must supply database and server'); | ||
expect(API.bind(API, userName, null, null, null, null, sessionId)).to.throw('Must supply database'); | ||
}); | ||
it('creates API with session id and a database but no server', function () { | ||
expect(API.bind(API, userName, null, database, null, null, sessionId)).to.throw('Must supply database and server'); | ||
expect(API.bind(API, userName, null, database, null, null, sessionId)).to.not.throw(); | ||
}); | ||
it('creates API with session id and a server but no database', function () { | ||
expect(API.bind(API, userName, null, null, server, null, sessionId)).to.throw('Must supply database and server'); | ||
expect(API.bind(API, userName, null, null, server, null, sessionId)).to.throw('Must supply database'); | ||
}); | ||
it('creates API with session id and a database, but a server that equals "my.geotab.com"', function () { | ||
expect(API.bind(API, userName, null, database, "my.geotab.com", null, sessionId)).to.throw('Must supply database and server'); | ||
expect(API.bind(API, userName, null, database, "my.geotab.com", null, sessionId)).to.not.throw(); | ||
}); | ||
@@ -80,0 +80,0 @@ |
Sorry, the diff of this file is not supported yet
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
0
33939