Skip to content

Commit d2d85de

Browse files
authored
Merge pull request #417 from NeoMod/patch-1
Fixed missing game link in notification for epic-games on captcha halt
2 parents 8d53829 + b3ab8f7 commit d2d85de

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

epic-games.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,8 @@ try {
198198

199199
if (btnText == 'in library') {
200200
console.log(' Already in library! Nothing to claim.');
201+
//await notify(`Game Already in Library! Follow is a test link:.\n Game link ${url}`); // Decomment this line if you want to also test if a link is beeing sent correctly in a notification. The "already in library" notification was missing, I find it usefull.
202+
await notify(`Game Already in Library!`); // decomment the previous line and comment this one if you also want to test for proper link-handling via notification.
201203
notify_game.status = 'existed';
202204
db.data[user][game_id].status ||= 'existed'; // does not overwrite claimed or failed
203205
if (db.data[user][game_id].status.startsWith('failed')) db.data[user][game_id].status = 'manual'; // was failed but now it's claimed
@@ -271,7 +273,7 @@ try {
271273
captcha.waitFor().then(async () => { // don't await, since element may not be shown
272274
// console.info(' Got hcaptcha challenge! NopeCHA extension will likely solve it.')
273275
console.error(' Got hcaptcha challenge! Lost trust due to too many login attempts? You can solve the captcha in the browser or get a new IP address.');
274-
await notify(`epic-games: got captcha challenge right before claim of <a href="${url}">${title}</a>. Use VNC to solve it manually.`); // TODO could even create purchase URL, see https://github.com/vogler/free-games-claimer/pull/130
276+
await notify(`epic-games: got captcha challenge.\n Game link ${url}`);// FIXED: Game link was not sent, probably error with html formatting? Anyway, the link is automatically parsed. TODO could even create purchase URL, see https://github.com/vogler/free-games-claimer/pull/130
275277
// await page.waitForTimeout(2000);
276278
// const p = path.resolve(cfg.dir.screenshots, 'epic-games', 'captcha', `${filenamify(datetime())}.png`);
277279
// await captcha.screenshot({ path: p });

0 commit comments

Comments
 (0)