mirror of
https://github.com/spacebarchat/server.git
synced 2026-08-23 03:09:52 +00:00
fix it the other way arround
This commit is contained in:
@@ -174,7 +174,21 @@ router.get(
|
||||
|
||||
const pins = await Message.find({
|
||||
where: { channel_id: channel_id, pinned_at: Not(IsNull()) },
|
||||
relations: { author: true },
|
||||
relations: {
|
||||
author: true,
|
||||
webhook: true,
|
||||
application: true,
|
||||
mentions: true,
|
||||
mention_roles: true,
|
||||
mention_channels: true,
|
||||
sticker_items: true,
|
||||
attachments: true,
|
||||
thread: {
|
||||
recipients: {
|
||||
user: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
order: { pinned_at: "DESC" },
|
||||
});
|
||||
|
||||
|
||||
@@ -243,7 +243,7 @@ export class Message extends BaseClass {
|
||||
member_id: undefined,
|
||||
webhook_id: this.webhook_id ?? undefined,
|
||||
application_id: undefined,
|
||||
mentions: this.mentions?.map((user) => {
|
||||
mentions: this.mentions.map((user) => {
|
||||
if (user && !user.toPublicUser) console.trace("toPublic user missing!!!");
|
||||
return user?.toPublicUser?.() ?? user ?? undefined;
|
||||
}),
|
||||
|
||||
Reference in New Issue
Block a user