MCPcopy Create free account
hub / github.com/Useful-Scripts-Extension/useful-script / searchAllGroupForOther

Function searchAllGroupForOther

scripts/fb_GLOBAL.js:552–578  ·  view source on GitHub ↗
(
  other_uid,
  uid,
  fb_dtsg,
  pageFetchedCallback
)

Source from the content-addressed store, hash-verified

550 }
551}
552export async function searchAllGroupForOther(
553 other_uid,
554 uid,
555 fb_dtsg,
556 pageFetchedCallback
557) {
558 let cursor = "";
559 let allGroups = [];
560 try {
561 while (true) {
562 let { nextCursor, data } = await searchGroupForOther(
563 other_uid,
564 cursor,
565 uid,
566 fb_dtsg
567 );
568 cursor = nextCursor;
569 allGroups = allGroups.concat(data);
570 await pageFetchedCallback?.(data, allGroups);
571
572 if (!cursor) break;
573 }
574 } catch (e) {
575 console.log("ERROR search all group for other", e);
576 }
577 return allGroups;
578}
579
580// =============================================================================
581// ================================== Helpers ==================================

Callers 1

Calls 2

searchGroupForOtherFunction · 0.85
concatMethod · 0.80

Tested by

no test coverage detected