Limit not working properly in contain section

When I use limit(1) in the contain section it does not work properly.

‘Expenses’ => function ($q){
return $q->where([
‘Expenses.is_paid’=>0,
‘Expenses.amount >’=>0,
])
->select([
‘Expenses.id’,
‘Expenses.payment_date’,
‘Expenses.amount’,
‘Expenses.is_paid’,
])
->order([‘Expenses.payment_date’=> ‘ASC’])
->limit([5]);

It might, it might not. :slight_smile:
Please let us know;
1- What you were doing (done)
2- What you expect
3- What you got instead.