mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-23 16:13:08 +02:00
upd: megalodon package fix lines, enable error on media
This commit is contained in:
parent
60b2842203
commit
8f219557d4
2 changed files with 4 additions and 4 deletions
|
@ -143,7 +143,7 @@ export class MastodonApiServerService {
|
||||||
const data = await client.uploadMedia(multipartData);
|
const data = await client.uploadMedia(multipartData);
|
||||||
reply.send(convertAttachment(data.data as Entity.Attachment));
|
reply.send(convertAttachment(data.data as Entity.Attachment));
|
||||||
} catch (e: any) {
|
} catch (e: any) {
|
||||||
/* console.error(e); */
|
console.error(e);
|
||||||
reply.code(401).send(e.response.data);
|
reply.code(401).send(e.response.data);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -161,7 +161,7 @@ export class MastodonApiServerService {
|
||||||
const data = await client.uploadMedia(multipartData, _request.body!);
|
const data = await client.uploadMedia(multipartData, _request.body!);
|
||||||
reply.send(convertAttachment(data.data as Entity.Attachment));
|
reply.send(convertAttachment(data.data as Entity.Attachment));
|
||||||
} catch (e: any) {
|
} catch (e: any) {
|
||||||
/* console.error(e); */
|
console.error(e);
|
||||||
reply.code(401).send(e.response.data);
|
reply.code(401).send(e.response.data);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -123,11 +123,11 @@ namespace MisskeyAPI {
|
||||||
noindex: null,
|
noindex: null,
|
||||||
suspended: null,
|
suspended: null,
|
||||||
limited: null,
|
limited: null,
|
||||||
created_at: u.createdAt,
|
created_at: u.createdAt ? u.createdAt : new Date().toUTCString(),
|
||||||
followers_count: u.followersCount,
|
followers_count: u.followersCount,
|
||||||
following_count: u.followingCount,
|
following_count: u.followingCount,
|
||||||
statuses_count: u.notesCount,
|
statuses_count: u.notesCount,
|
||||||
note: u.description,
|
note: u.description ? u.description : '',
|
||||||
url: acct,
|
url: acct,
|
||||||
avatar: u.avatarUrl,
|
avatar: u.avatarUrl,
|
||||||
avatar_static: u.avatarColor,
|
avatar_static: u.avatarColor,
|
||||||
|
|
Loading…
Reference in a new issue