made-in-generator
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -17,2 +17,3 @@ 'use strict'; | ||
const SORTS = [undefined, 'followers', 'repositories', 'joined']; // undefined will be used best match | ||
const DELAY = 60 * 1000; | ||
@@ -22,2 +23,3 @@ const LOWEST_STAR = 3; | ||
const MAXIMUM_LENGTH = 30; | ||
const MAXIMUM_PAGE = 33; | ||
@@ -141,2 +143,3 @@ const filepath = _.transform([ | ||
location, | ||
sort: 0, | ||
page: index === 0 ? page : 1 | ||
@@ -148,2 +151,3 @@ }; | ||
q: `location:${location}`, | ||
sort: SORTS[info.sort], | ||
page: info.page | ||
@@ -154,5 +158,10 @@ }; | ||
.then(items => { | ||
info.page++; | ||
const developers = _.map(items, 'login'); | ||
this._developers.push(...developers); | ||
if (info.page++ > MAXIMUM_PAGE) { | ||
info.page = 0; | ||
if (++info.sort === SORTS.length) { | ||
return []; | ||
} | ||
} | ||
return developers; | ||
@@ -159,0 +168,0 @@ }); |
{ | ||
"name": "made-in-generator", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "Geneator of made-in-xxx", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
16628
450
0