Skip to content

Commit 068c8c3

Browse files
authoredMay 25, 2022
Merge pull request #18 from poignart/dev
added error logs for twitter
2 parents 8a5fa30 + 44ade8b commit 068c8c3

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed
 

‎src/utils/twitter.ts

+7-1
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,10 @@ export const getNewMintMessage = (
2727
2828
#Unchain_Ukraine #StandWithUkraine ${FRONTEND_URL}/voucher/${voucherId}`;
2929

30-
export const tweetMessage = (body: string) => CLIENT.readWrite.v2.tweet(body);
30+
export const tweetMessage = async (body: string) => {
31+
try {
32+
await CLIENT.readWrite.v2.tweet(body);
33+
} catch (error) {
34+
console.error('Error tweeting message:', error);
35+
}
36+
};

0 commit comments

Comments
 (0)
Please sign in to comment.