Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

floodesh

Package Overview
Dependencies
Maintainers
1
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

floodesh - npm Package Compare versions

Comparing version 0.8.8 to 0.8.9

42

client/index.js

@@ -117,11 +117,3 @@

logClient.info("Start fetching job from seed.");
this.emit(JOB_QUEUE,this.seed.map(item=>this._toJob(item)),(e) => {
logClient.silly("Inserted jobs. Here in callback.");
this.dbTasks.pop();
if(e)
return logClient.error(e);
this._dequeue(this._dehandler);
} );
this.emit(JOB_QUEUE,this.seed.map(item=>this._toJob(item)),() => this._dequeue(this._dehandler));
}

@@ -136,3 +128,3 @@ }.bind(this);

if(items.length===0)
return;
return callback();

@@ -147,8 +139,9 @@ let bulk = this.db.collection(this.name).initializeUnorderedBulkOp();

logClient.silly("Inserting jobs to mongodb...");
bulk.execute(callback);
// bulk.execute(err => {
// logClient.silly("Inserted jobs. Here in callback.");
// if(err) logClient.error(err);
// self.dbTasks.pop();
// });
//bulk.execute(callback);
bulk.execute(err => {
logClient.silly("Inserted jobs. Here in callback.");
if(err) logClient.error(err);
self.dbTasks.pop();
callback();
});
});

@@ -187,5 +180,5 @@ }

_enqueue(jobs, callback){
if(jobs.length === 0)
return;
if(0 === jobs.length)
return callback();
let items = [], requests=[], self=this;

@@ -206,2 +199,3 @@ for(let i=0;i<jobs.length;i++){

logClient.error(err);
return callback();
}else{

@@ -362,11 +356,3 @@ logClient.verbose(result);

// res must be a job format, cannot handle
self._enqueue(res,e => {
logClient.silly("Inserted jobs. Here in callback.");
self.dbTasks.pop();
if(e)
logClient.error(e);
self.emit(JOB_END,objJob,Status.success);
});
self._enqueue(res,() => self.emit(JOB_END,objJob,Status.success));
});

@@ -373,0 +359,0 @@ }

{
"name": "floodesh",
"version": "0.8.8",
"version": "0.8.9",
"description": "Floodesh is a distributed web spider/crawler written with Nodejs.",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc