Error handling with expiered login and wrong input in telegram
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
{{$('global_params').item.json.set_viewport}}
|
||||
{{$('global_params').item.json.js_functions}}
|
||||
{{$('global_params').item.json.image_data}}
|
||||
|
||||
async function click_replies(page, selector_comment_body, selector_replies) {
|
||||
for (i = 0; i < 1; i++) {
|
||||
try {
|
||||
@@ -39,8 +43,10 @@ async function extract_comments(page, data, selector_comment_body) {
|
||||
return data
|
||||
}
|
||||
|
||||
const { cookies } = $input.first().json;
|
||||
deal_url = $input.last().json['url'];
|
||||
|
||||
|
||||
|
||||
deal_url = $('global_params').item.json.mydealz_url;
|
||||
|
||||
const selector_replies = "button[data-t='moreReplies']";
|
||||
const selector_comment_body = ".comment-body";
|
||||
@@ -48,10 +54,17 @@ const sel_next_page = "::-p-aria(Nächste Seite)";
|
||||
var data = [];
|
||||
|
||||
// Restore cookies
|
||||
await $page.setCookie(...cookies);
|
||||
try {
|
||||
const cookies= $json;
|
||||
await $page.setCookie(...cookies);
|
||||
} catch {
|
||||
const cookies= $('convert_to_json').item.json.data[0];
|
||||
await $page.setCookie(...cookies);
|
||||
}
|
||||
|
||||
// Navigate to authenticated page
|
||||
await $page.goto(deal_url);
|
||||
await cookie_banner_click();
|
||||
|
||||
try {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user