Change innerJoin to leftJoin, so that every contribution is shown not only the one with messages.

This commit is contained in:
elweyn 2022-08-24 16:43:32 +02:00
parent a9c3dd25ed
commit 057816e4c0

View File

@ -98,8 +98,8 @@ export class ContributionResolver {
.createQueryBuilder()
.select('c')
.from(dbContribution, 'c')
.innerJoinAndSelect('c.messages', 'm')
.innerJoinAndSelect('m.user', 'u')
.leftJoinAndSelect('c.messages', 'm')
.leftJoinAndSelect('m.user', 'u')
.orderBy('c.createdAt', order)
.limit(pageSize)
.offset((currentPage - 1) * pageSize)