mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
Moved the filter on creation to the query.
This commit is contained in:
parent
f7af70625e
commit
13642133c1
@ -359,6 +359,7 @@ async function listTransactions(
|
||||
limit,
|
||||
offset,
|
||||
order,
|
||||
onlyCreations,
|
||||
)
|
||||
skipFirstTransaction = userTransactionsCount > offset + limit
|
||||
const decay = !(currentPage > 1)
|
||||
@ -380,11 +381,6 @@ async function listTransactions(
|
||||
|
||||
const transactionList = new TransactionList()
|
||||
transactionList.count = userTransactionsCount
|
||||
if (onlyCreations) {
|
||||
transactions = transactions.filter((transaction) => {
|
||||
return transaction.type === 'creation'
|
||||
})
|
||||
}
|
||||
transactionList.transactions = transactions
|
||||
return transactionList
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user