MCPcopy Create free account
hub / github.com/TributePaulWalker/Profiles / getDataInfo

Function getDataInfo

JavaScript/Surge/Sub_info_lite.js:98–113  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

96}
97
98async function getDataInfo(url) {
99 const [err, data] = await getUserInfo(url)
100 .then((data) => [null, data])
101 .catch((err) => [err, null]);
102 if (err) {
103 console.log(err);
104 return;
105 }
106
107 return Object.fromEntries(
108 data
109 .match(/\w+=\d+/g)
110 .map((item) => item.split("="))
111 .map(([k, v]) => [k, parseInt(v)])
112 );
113}
114
115function getRmainingDays(resetDay) {
116 if (!resetDay) return 0;

Callers 1

Sub_info_lite.jsFile · 0.85

Calls 2

getUserInfoFunction · 0.85
logMethod · 0.45

Tested by

no test coverage detected