Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
ClientSession.prototype.registerNodes = function(nodesToRegister,callback) {
const self = this;
assert(_.isFunction(callback));
assert(_.isArray(nodesToRegister));
const request = new register_node_service.RegisterNodesRequest({
nodesToRegister: nodesToRegister.map(resolveNodeId)
});
self.performMessageTransaction(request, function (err, response) {
/* istanbul ignore next */
if (err) {
return callback(err);
}
assert(response instanceof register_node_service.RegisterNodesResponse);
callback(null, response.registeredNodeIds);
});
};