Skip to content

Commit f249d8f

Browse files
authored
fix: add utf-8 explicitly (#463)
* fix: add utf-8 explicitly * fix: changeset
1 parent a2273aa commit f249d8f

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

.changeset/wise-bugs-admire.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"lingo.dev": patch
3+
"@lingo.dev/_sdk": patch
4+
---
5+
6+
set utf-8 encoding explicitly

packages/sdk/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ export class ReplexicaEngine {
100100
const res = await fetch(`${this.config.apiUrl}/i18n`, {
101101
method: "POST",
102102
headers: {
103-
"Content-Type": "application/json",
103+
"Content-Type": "application/json; charset=utf-8",
104104
Authorization: `Bearer ${this.config.apiKey}`,
105105
},
106106
body: JSON.stringify(
@@ -414,7 +414,7 @@ export class ReplexicaEngine {
414414
const response = await fetch(`${this.config.apiUrl}/recognize`, {
415415
method: "POST",
416416
headers: {
417-
"Content-Type": "application/json",
417+
"Content-Type": "application/json; charset=utf-8",
418418
Authorization: `Bearer ${this.config.apiKey}`,
419419
},
420420
body: JSON.stringify({ text }),

0 commit comments

Comments
 (0)