Skip to content

[5.4] Eloquent model 'isNot' complement method#20354

Merged
taylorotwell merged 3 commits into
laravel:5.4from
timacdonald:model-isNot
Aug 1, 2017
Merged

[5.4] Eloquent model 'isNot' complement method#20354
taylorotwell merged 3 commits into
laravel:5.4from
timacdonald:model-isNot

Conversation

@timacdonald

@timacdonald timacdonald commented Aug 1, 2017

Copy link
Copy Markdown
Member

In Eloquent $model->is($otherModel) now has the complement method $model->isNot($otherModel).

In my latest project I added this to my eloquent base model and thought I'd see if there was any interest for the core.

@taylorotwell taylorotwell merged commit e599814 into laravel:5.4 Aug 1, 2017
JosephSilber added a commit to JosephSilber/bouncer that referenced this pull request Aug 3, 2017
Laravel (in 5.4.31) added its own "isNot" method to the base Eloquent
Model class. Pull: laravel/framework#20354
So we unfortunately have to remove our alias, which fixes #187.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants