lookinlab/adonis-lucid-soft-deletes

GroupLimit create an error

Closed this issue · 3 comments

Hello,

Using Soft deletes on a preloaded model with group limit will create an error :

 const associations = await Association.query()
      .preload('tags', (tags) => tags.groupLimit(3))
      .paginate(page, this.PER_PAGE)

There is an error because the no retrieval of deleted items clause is added at the end of the query.

image

Hi, @Barbapapazes
If you disable Soft Deletes for tags, does the query work?

Yes ! It works fine without SoftDeletes

Fixed in v1.4.1