Skip to content

Releases: tylernathanreed/laravel-relation-joins

v7.0.0

13 Dec 21:15
286425b
Compare
Choose a tag to compare

Out with PHP 8.1, in with PHP 8.4

PHP 8.1 reached its end of active support life over a year ago (security support will continue until EOY 2025). I have dropped support for PHP 8.1 (you can continue using it if you're on the 6.x release), and I've formally added support for PHP 8.4.

Relation Generics

There was also a change within Laravel 11 (#51851) which added generics to relations. I've updated the static analysis within this package to support those generics as well. There may be additional changes in the future as people start trying out query scopes within joins, as PHPStan/Larastan should now be able to detect that the join clause is for a specific model.

Breaking Change

The dynamic addition of properties has been deprecated in PHP 8.4, so the ability to modify join types via $join->type = 'left' has been removed, as it relied on this feature. You'll have to piece together your joins in another manner now.

Before:

User::query()->joinRelation('posts.comments', [
    'comments' => function ($join) { $join->type = 'left'; }
});

After:

User::query()
    ->joinRelation('posts')
    ->leftJoinThroughRelation('posts.comments');

v6.0.1

20 Mar 17:08
Compare
Choose a tag to compare

This is more of a technical release.

The PHPStan level has been increased from 6 to 8, and the GitHub actions have been bumped from Node 16 to Node 20.

These changes help maintain the quality of each release.

v6.0.0

20 Mar 15:22
Compare
Choose a tag to compare

Laravel 9 reached its end of life earlier this year. I have dropped support for L9, and added official support for Laravel 11.

With this comes dropping PHP 8.0, with the new minimum of PHP 8.1.

v5.0.0

25 Sep 20:47
Compare
Choose a tag to compare

Laravel 8 reached its end of life earlier this year. I have dropped support for L8, and added future compatibility for the upcoming Laravel 11.

With this comes dropping PHP 7.3, with the new minimum of PHP 8.0.

PHP 8 offers better type-hinting, and overall works better with static analysis tooling. I have incorporated PHP Stan into the pipeline builds moving forward to offer better quality code for everyone.

v4.0.2

25 Sep 20:19
f8f0ee8
Compare
Choose a tag to compare

Fixed #25.

v4.0.1

01 Apr 17:23
Compare
Choose a tag to compare

Fixed aliasing error with morphOne relationship

Laravel 10.x Support

01 Apr 17:00
3b001f6
Compare
Choose a tag to compare

Added Laravel 10.x support.

Dropped Laravel 7.x support.

Fixed strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated

Laravel 9.x Support

09 Feb 15:30
9436207
Compare
Choose a tag to compare

Added Laravel 9 support.

Dropped Laravel 6.x support.

Fixed code coverage

25 Jul 22:34
Compare
Choose a tag to compare
v2.4.2

~ Explain things and fix code coverage

Added support for mixed join types in array-syntax

25 Jul 22:23
Compare
Choose a tag to compare

Example:

User::query()->joinRelation('posts.comments', [
    'comments' => function ($join) { $join->type = 'left'; }
});