Skip to content

Commit e829dba

Browse files
committed
add User-Agent after optional headers
1 parent 12367d5 commit e829dba

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/request.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,11 @@ export async function request({
5555
{
5656
...options,
5757
headers: {
58-
"User-Agent": `twitter-api-typescript-sdk/1.0.0`,
5958
...options.headers,
60-
...(isPost ? { "Content-Type": "application/json; charset=utf-8" } : undefined),
59+
"User-Agent": `twitter-api-typescript-sdk/1.0.0`,
60+
...(isPost
61+
? { "Content-Type": "application/json; charset=utf-8" }
62+
: undefined),
6163
...authHeader,
6264
},
6365
method,

0 commit comments

Comments
 (0)