MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / redeem

Function redeem

src/lib/secureAdRewardState.js:23–32  ·  view source on GitHub ↗
(offerId)

Source from the content-addressed store, hash-verified

21 }
22 },
23 async redeem(offerId) {
24 try {
25 const raw = await execSystem("redeemReward", [offerId]);
26 if (!raw) return null;
27 return typeof raw === "string" ? JSON.parse(raw) : raw;
28 } catch (error) {
29 console.warn("Failed to redeem rewarded ad offer.", error);
30 throw error;
31 }
32 },
33};

Callers

nothing calls this directly

Calls 1

execSystemFunction · 0.85

Tested by

no test coverage detected