Skip to content

Commit

Permalink
Tri des achats abos par date de début de début
Browse files Browse the repository at this point in the history
  • Loading branch information
gfra54 committed Sep 5, 2024
1 parent fa00ca3 commit 3a983a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/models/subscription.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export async function getMemberSubscriptions(memberId) {
const subscriptions = await mongo.db.collection('subscriptions').find({memberId}).toArray()
return chain(subscriptions)
.map(s => formatSubscription(s))
.orderBy(['purchased'], ['desc'])
.orderBy(['purchased', 'started'], ['desc', 'desc'])
.value()
}

Expand Down

0 comments on commit 3a983a7

Please sign in to comment.