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

Function getShares

scripts/backup/code-f12-toolkit.js:48–71  ·  view source on GitHub ↗
(e, n, o = !1)

Source from the content-addressed store, hash-verified

46 a.send();
47 };
48 var getShares = (e, n, o = !1) => {
49 o ||
50 (o =
51 "https://graph.facebook.com/" +
52 n +
53 "/comments?limit=5000&fields=from.id&access_token=" +
54 e);
55 var t = new XMLHttpRequest();
56 t.open("GET", o),
57 t.send(),
58 (t.onreadystatechange = () => {
59 if (4 == t.readyState && 200 == t.status) {
60 var e = JSON.parse(t.responseText);
61 e.data.forEach((e) => {
62 void 0 !== friendsList[e.from.id] &&
63 (friendsList[e.from.id].point += 1);
64 }),
65 void 0 !== e.paging && void 0 !== e.paging.next
66 ? console_log("Continue scanning reactions for " + n)
67 : (console_log("Scanned comments on post " + n),
68 completedPosts.push(n));
69 }
70 });
71 },
72 getComments = (e, n, o = !1) => {
73 o ||
74 (o =

Callers 1

getCommentsFunction · 0.85

Calls 2

console_logFunction · 0.85
parseMethod · 0.80

Tested by

no test coverage detected