Skip to content

Commit

Permalink
added asert checking of arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
samofab committed Aug 5, 2015
1 parent e8d0f6e commit 6bfea34
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion nisa32.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,12 @@ exports.query = function (visaAddress, queryString, callback){
};

function nisaQuery(visaAddress, queryString, callback){

assert.equal(typeof (visaAddress), 'string', "argument 'visaAddress' must be a string");
assert.equal(typeof (queryString), 'string', "argument 'queryString' must be a string");
assert.equal(typeof (callback), 'function');
// assert.equal(typeof (timeout), 'number', "argument 'timeout' must be a number");
// assert.ok(!isNaN(timeout) && timeout > 0, "argument 'timeout' must be a positive integer");

var resourceManager = '0';
var viError = 0;
var session = 0;
Expand Down

0 comments on commit 6bfea34

Please sign in to comment.