try again

This commit is contained in:
cutestnekoaqua 2023-02-13 20:41:42 +01:00
parent c4683c0196
commit a607673019

View File

@ -304,11 +304,11 @@ export function apiAccountMastodon(router: Router): void {
const client = getClient(BASE_URL, accessTokens);
let users;
try {
const idsRaw = ctx.query["id[]"];
const idsRaw = ctx.request.body?["id[]"] : null;
const ids = typeof idsRaw === "string" ? [idsRaw] : idsRaw;
users = ids;
relationshopModel.id = idsRaw?.toString() || "1";
if (!idsRaw) {
if (!(idsRaw && ids)) {
ctx.body = [relationshopModel];
return;
}