Oopsie
This commit is contained in:
5
app.js
5
app.js
@@ -3,8 +3,7 @@ import express from "express";
|
||||
import {Logger} from "./wwwroot/core/logging/logger.js";
|
||||
import {launch} from "./bot.js";
|
||||
|
||||
//await launch();
|
||||
console.log(data.instagramTokenManager.getOauthUrl());
|
||||
await launch();
|
||||
|
||||
const app = express();
|
||||
app.use(express.json());
|
||||
@@ -15,10 +14,8 @@ app.get("/oauth/", async (req, res) => {
|
||||
try{
|
||||
const shortLived = await data.instagramTokenManager.generateShortLivedToken(code);
|
||||
const longLived = await data.instagramTokenManager.generateLongLivedToken(shortLived);
|
||||
console.log(longLived);
|
||||
resMsg = "Authentication successful. You can close this tab";
|
||||
} catch(err){
|
||||
console.log(err);
|
||||
await Logger.error(`Unable to generate token from code ${code}`, err);
|
||||
resMsg = "An error occurred. Try again in few minutes.";
|
||||
} finally {
|
||||
|
||||
Reference in New Issue
Block a user