add depth thing back
This commit is contained in:
parent
e508f75408
commit
55fa60f13d
1 changed files with 8 additions and 0 deletions
8
site.js
8
site.js
|
@ -82,11 +82,19 @@ async function siteCollector(user, path, site, useLimit) {
|
|||
let ca = await siteCollector(u, 'followers', site);
|
||||
users = users.concat(ca);
|
||||
legal = legal.concat(ca);
|
||||
|
||||
users = users.concat(await siteCollector(u, 'following', site));
|
||||
}
|
||||
|
||||
users = [...new Set(users)];
|
||||
|
||||
let d = process.env.depth || 1;
|
||||
for (let i = 1; i < d; i++) {
|
||||
for (let u of users) {
|
||||
users = users.concat(await siteCollector(u, 'following', site, true));
|
||||
}
|
||||
}
|
||||
|
||||
let data = {};
|
||||
let p = [];
|
||||
let congested = [];
|
||||
|
|
Loading…
Reference in a new issue