Package to convert Eloquent BelongsTo subqueries into one query with left join