This commit is contained in:
tursom 2024-10-21 14:25:03 +08:00
parent d5dfaa54c3
commit ea948e017a
2 changed files with 3 additions and 1 deletions

View File

@ -88,6 +88,9 @@ async function sendImg(req, res) {
client.steamCommunity.sendImageToUser(requests.id, img, function (err, imageUrl) {
if (err) {
logger.error("an error occurred while sending image: ", err);
client.steamUser.webLogOn();
res.statusCode = 500;
res.setHeader('Content-Type', 'text/plain');
res.end('Internal Server Error\n');

View File

@ -68,7 +68,6 @@ steamWebLoginPromise = new Promise((resolve, reject) => {
steamUser.on('webSession', async (sessionID, cookies) => {
logger.info(`web session received: ${sessionID}`);
webLogOn = true;
steamCommunity.setCookies(cookies);
steamCommunity.startConfirmationChecker(10000, config.identitySecret);