Update Webmentions.astro
This commit is contained in:
@@ -570,7 +570,11 @@ const getEndpoint = endpoint ? getWebmentionEndpoint(endpoint, 'get') : '';
|
|||||||
fetch(form.action, {
|
fetch(form.action, {
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
body,
|
body,
|
||||||
headers: { Accept: 'application/json' }
|
// webmentiond currently requires this Content-Type without a charset suffix.
|
||||||
|
headers: {
|
||||||
|
Accept: 'application/json',
|
||||||
|
'Content-Type': 'application/x-www-form-urlencoded'
|
||||||
|
}
|
||||||
}).then(async (response) => {
|
}).then(async (response) => {
|
||||||
if (!response.ok) {
|
if (!response.ok) {
|
||||||
const message = plainText(await response.text());
|
const message = plainText(await response.text());
|
||||||
|
|||||||
Reference in New Issue
Block a user