mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-22 09:57:29 -07:00
[mastodon-client] Fix posting statuses with attachment
This commit is contained in:
parent
1f8c735889
commit
37b21f973f
1 changed files with 3 additions and 0 deletions
|
@ -59,6 +59,9 @@ export function apiStatusMastodon(router: Router): void {
|
|||
}
|
||||
if (!body.media_ids) body.media_ids = undefined;
|
||||
if (body.media_ids && !body.media_ids.length) body.media_ids = undefined;
|
||||
if (body.media_ids) {
|
||||
body.media_ids = (body.media_ids as string[]).map(p => convertId(p, IdType.CalckeyId));
|
||||
}
|
||||
const { sensitive } = body;
|
||||
body.sensitive =
|
||||
typeof sensitive === "string" ? sensitive === "true" : sensitive;
|
||||
|
|
Loading…
Reference in a new issue