Skip to content

Commit

Permalink
feat: libre url updated
Browse files Browse the repository at this point in the history
  • Loading branch information
ParvinEyvazov committed Sep 1, 2022
1 parent 4192b72 commit 548dce2
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/core/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,14 @@ async function translateWithLibre(
console.log('body:', body);

const { data } = await axios.post(
'https://libretranslate.com/translate',
'https://translate.argosopentech.com/translate',
body,
{ headers: { Origin: 'https://libretranslate.com' } }
{
headers: {
Origin: 'https://translate.argosopentech.com',
Referer: 'https://translate.argosopentech.com',
},
}
);

return data?.translatedText ? data?.translatedText : default_value;
Expand Down

0 comments on commit 548dce2

Please sign in to comment.