|
|
@ -18,7 +18,7 @@ const gistClient = axios.create({
|
|
|
|
}
|
|
|
|
}
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
async function tweet(content, encodedImage) {
|
|
|
|
function tweet(content, encodedImage) {
|
|
|
|
const processedData = encodedImage.split(',')[1]
|
|
|
|
const processedData = encodedImage.split(',')[1]
|
|
|
|
|
|
|
|
|
|
|
|
return client
|
|
|
|
return client
|
|
|
@ -70,6 +70,6 @@ function checkIfRateLimited(err) {
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
client,
|
|
|
|
client,
|
|
|
|
getGist,
|
|
|
|
getGist,
|
|
|
|
tweet: debounce(tweet, ms('5s'), { leading: true, trailing: true }),
|
|
|
|
tweet: debounce(tweet, ms('5s'), { leading: true, trailing: false }),
|
|
|
|
image: debounce(image, ms('5s'), { leading: true, trailing: true })
|
|
|
|
image: debounce(image, ms('5s'), { leading: true, trailing: false })
|
|
|
|
}
|
|
|
|
}
|
|
|
|