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

Function getComments

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

Source from the content-addressed store, hash-verified

70 });
71 },
72 getComments = (e, n, o = !1) => {
73 o ||
74 (o =
75 "https://graph.facebook.com/" +
76 n +
77 "/comments?limit=5000&fields=from.id&access_token=" +
78 e);
79 var t = new XMLHttpRequest();
80 t.open("GET", o),
81 t.send(),
82 (t.onreadystatechange = () => {
83 if (4 == t.readyState && 200 == t.status) {
84 var o = JSON.parse(t.responseText);
85 o.data.forEach((e) => {
86 void 0 !== friendsList[e.from.id] &&
87 (friendsList[e.from.id].point += 1);
88 }),
89 void 0 !== o.paging && void 0 !== o.paging.next
90 ? console_log("Continue scanning reactions for " + n)
91 : (console_log("Scanned comments on post " + n),
92 getShares(e, n));
93 }
94 });
95 },
96 getReactions = (e, n, o = !1) => {
97 o ||
98 (o =

Callers 1

getReactionsFunction · 0.85

Calls 3

console_logFunction · 0.85
getSharesFunction · 0.85
parseMethod · 0.80

Tested by

no test coverage detected