Dyceman
-
Posts
6 -
Joined
-
Last visited
Posts posted by Dyceman
-
-
Can you post the code?
-
I created a work around until I get a reply. If anyone else is running into this issue then use the below code.
community.getNotifications(function(err, notifications) // Used to check if the user is logged in. { if(err.toString().indexOf("HTTP error 401") > -1) { console.log("Saved Announcement"); announcements.push({title: title, body: body}); client.webLogOn(); } else { community.postGroupAnnouncement(config.steam_group_id, title, body, function(err) // Doesn't check if the user is logged in...... -.- { if(err != null) { console.log(err); response.status(500).send("An error has occured, check your console."); } else { console.log("Posted Announcement Successfully!"); response.status(200).send("Posted Announcement Successfully!"); } }); } });
-
The postGroupAnnouncement doesn't trigger sessionExpired if the session is expired because the err object never displays the "Not Logged In" error.
Because of the this issue mentioned above you can't post announcements or log back in from the postGroupAnnoucement.
Is there a way around this issue?
My code.
community.postGroupAnnouncement(config.steam_group_id, title, body, function(err) { console.log(err); // Displays null if the session is expired. if(err != null) { if(err.toString().indexOf("Not Logged In") > -1) // Never is triggered. { console.log("Saved Announcement"); announcements.push({title: title, body: body}); } else { console.log(err); response.status(500).send("An error has occured, check your console."); } } else { console.log("Posted Announcement Successfully!"); response.status(200).send("Posted Announcement Successfully!"); } });
-
I am currently having the same issue.
-
Could some assist me in disabling my bot's session from ever timing out?
Steam Game News
in General
Posted
Is it possible to obtain steam game news using any of your libraries?