I tried using .match() method in node.js and the console returns has no method 'match'. This is the part where I call the method:
fs.readFile('proxy.txt', function (err, data) {
if (data.match('\n').length < proxyNum) {
proxyNum = data.match('\n').length;
}
console.log('Testing ' + proxyNum + 'proxies.');
});
Any idea how I could properly call .match()?
Aucun commentaire:
Enregistrer un commentaire