Set correct content type to json
This commit is contained in:
@@ -95,7 +95,7 @@ async function loginToTinyTinyRSS() {
|
||||
const loginResponse = await fetch("https://news.nas.franpenedo.com/api/", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/x-www-form-urlencoded",
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
body: JSON.stringify({ op: "login", user: creds.usr, password: creds.pword }),
|
||||
});
|
||||
@@ -114,7 +114,7 @@ async function subscribeToFeed(feedURL, sessionID) {
|
||||
const subscribeResponse = await fetch("https://news.nas.franpenedo.com/api/", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/x-www-form-urlencoded",
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
body: JSON.stringify({ op: "subscribeToFeed", feed_url: feedURL, category_id: 11, sid: sessionID }),
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user