Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(): update deps #91

Merged
merged 3 commits into from
Oct 15, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions lib/portfinder.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var fs = require('fs'),
os = require('os'),
net = require('net'),
path = require('path'),
async = require('async'),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

after consideration, if we do merge - change the word async to _async or some other non reserved keyword from ecmascript

/globally

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed to _async. I am not sure this is really needed.

_async = require('async'),
debug = require('debug'),
mkdirp = require('mkdirp').mkdirp;

Expand Down Expand Up @@ -142,7 +142,7 @@ exports.getPort = function (options, callback) {
}

var openPorts = [], currentHost;
return async.eachSeries(exports._defaultHosts, function(host, next) {
return _async.eachSeries(exports._defaultHosts, function(host, next) {
debugGetPort("in eachSeries() iteration callback: host is", host);

return internals.testPort({ host: host, port: options.port }, function(err, port) {
Expand Down Expand Up @@ -244,7 +244,7 @@ exports.getPorts = function (count, options, callback) {
}

var lastPort = null;
async.timesSeries(count, function(index, asyncCallback) {
_async.timesSeries(count, function(index, asyncCallback) {
if (lastPort) {
options.port = exports.nextPort(lastPort);
}
Expand Down
37 changes: 23 additions & 14 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@
"lib"
],
"dependencies": {
"async": "^1.5.2",
"debug": "^2.2.0",
"mkdirp": "0.5.x"
"async": "^2.6.2",
"debug": "^3.1.1",
"mkdirp": "^0.5.1"
},
"devDependencies": {
"glob": "^6.0.4",
"glob": "^7.1.4",
"vows": "^0.8.2"
},
"main": "./lib/portfinder",
Expand Down
4 changes: 2 additions & 2 deletions test/helper.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"use strict";

var async = require('async'),
var _async = require('async'),
http = require('http');


Expand Down Expand Up @@ -30,7 +30,7 @@ module.exports = function(servers, startPort, endPort, callback) {
var base = startPort || 32768;
endPort = endPort || 32773;

async.whilst(
_async.whilst(
function () { return base < endPort; },
function (next) {
var hosts = ['localhost'];
Expand Down
4 changes: 2 additions & 2 deletions test/port-finder-socket-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var assert = require('assert'),
exec = require('child_process').exec,
net = require('net'),
path = require('path'),
async = require('async'),
_async = require('async'),
vows = require('vows'),
portfinder = require('../lib/portfinder'),
fs = require('fs'),
Expand All @@ -24,7 +24,7 @@ var servers = [],
function createServers (callback) {
var base = 0;

async.whilst(
_async.whilst(
function () { return base < 5 },
function (next) {
var server = net.createServer(function () { }),
Expand Down