1
0
mirror of https://github.com/andrigamerita/simpkey synced 2025-06-05 22:09:26 +02:00
This commit is contained in:
Xeltica
2020-07-24 14:18:17 +09:00
parent a4c54edb54
commit 9cc01202e4
2 changed files with 6 additions and 1 deletions

View File

@ -228,11 +228,12 @@ router.post('/action/:action', async ctx => {
try {
switch (action) {
case 'create-note': {
const { text, renoteId, replyId } = ctx.request.body;
const { text, renoteId, replyId, useCw, cw } = ctx.request.body;
const opts = { i } as Record<string, string>;
if (text) opts.text = text;
if (renoteId) opts.renoteId = renoteId;
if (replyId) opts.replyId = replyId;
if (useCw) opts.cw = cw || '';
await api(host, 'notes/create', opts);
break;
}