utils.hastebin: set content type
This commit is contained in:
parent
f375acf9c8
commit
d929e6ffb3
1 changed files with 3 additions and 2 deletions
|
@ -153,9 +153,10 @@ async function getImage(msg, str) {
|
||||||
async function hastebin(body) {
|
async function hastebin(body) {
|
||||||
const res = await fetch(`https://nekobin.com/api/documents`, {
|
const res = await fetch(`https://nekobin.com/api/documents`, {
|
||||||
method: "POST",
|
method: "POST",
|
||||||
body: JSON.stringify({content:body}),
|
headers: {"Content-Type": "application/json"},
|
||||||
|
body: JSON.stringify({content: body}),
|
||||||
}).then((r) => r.json());
|
}).then((r) => r.json());
|
||||||
return "https://nekobin.com"+res.result.key;
|
return "https://nekobin.com" + res.result.key;
|
||||||
}
|
}
|
||||||
|
|
||||||
hf.selectionMessages = hf.selectionMessages || new Eris.Collection();
|
hf.selectionMessages = hf.selectionMessages || new Eris.Collection();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue