Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async function getUserAuth(consumerKey, consumerSecret) {
const log = new Signale({ interactive: true });
const oauth = new Flickr.OAuth(consumerKey, consumerSecret);
try {
log.await("Requesting authorization token");
const { body } = await oauth.request("");
log.success(
"Authorization token retrieved",
body.oauth_token,
body.oauth_token_secret
);
return Flickr.OAuth.createPlugin(
consumerKey,
consumerSecret,
body.oauth_token,
body.oauth_token_secret
);