mirror of
https://github.com/spacebarchat/server.git
synced 2026-10-22 19:43:16 +00:00
Fix read state type field - fixes #1559
This commit is contained in:
1 parent
785f53e7d1
commit
49516f018c
1 file changed
+1
-1
@@ -444,7 +444,7 @@ export async function handleMessage(opts: MessageOptions): Promise<Message> {
|
||||
await fillInMissingIDs((await Member.find({ where: { guild_id: channel.guild_id } })).map(({ id }) => id));
|
||||
}
|
||||
const repository = ReadState.getRepository();
|
||||
const condition = { channel_id: channel.id, type: ReadStateType.CHANNEL };
|
||||
const condition = { channel_id: channel.id, read_state_type: ReadStateType.CHANNEL };
|
||||
await repository.update({ ...condition, mention_count: IsNull() }, { mention_count: 0 });
|
||||
await repository.increment(condition, "mention_count", 1);
|
||||
} else {
|
||||
|
||||
Reference in new issue
Block a user