This commit is contained in:
Jeff McAffer 2016-11-20 23:11:39 -08:00
Родитель 2e7e5c08e4
Коммит a3df9e0f49
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -115,6 +115,7 @@ class Crawler {
request.crawler = self;
request.crawlerName = options.name;
requestBox[0] = request;
request.context = request.context || {};
request.promises = [];
return request;
})
@ -347,9 +348,8 @@ class Crawler {
_createQueuable(request) {
// Create a new request data structure that has just the things we should queue
const queuable = new Request(request.type, request.url);
const queuable = new Request(request.type, request.url, request.context);
queuable.attemptCount = request.attemptCount;
queuable.context = request.context;
queuable.force = request.force;
queuable.subType = request.subType;
return queuable;