Framework: L5.7 Undefined variable for Mail Vendor

Created on 4 Sep 2018  路  2Comments  路  Source: laravel/framework

  • Laravel Version: 5.7.0

Description:

Vendor mail html >
button.blade.php (Undefined color variable)
layout.blade.php
in Laravel 5.6, it was working fine. Only problem with Laravel 5.7

Most helpful comment

OK, all my tests are passing now.

The problem is caused by using 5.6 Laravel vendor files, that used "or" rather than "??" for some data fields. As noted in the 5.7 upgrade guide, Laravel has removed support for "or." You can fix the problem by either replacing the old vendor files or by manually updating those lines.

All 2 comments

I'm having the same issue, but it only pops up when I run phpunit on Codeship. I think it may be related to the following:

// Laravel 5.6...
{{ $foo or 'default' }}

// Laravel 5.7...
{{ $foo ?? 'default' }}

I will test now.

OK, all my tests are passing now.

The problem is caused by using 5.6 Laravel vendor files, that used "or" rather than "??" for some data fields. As noted in the 5.7 upgrade guide, Laravel has removed support for "or." You can fix the problem by either replacing the old vendor files or by manually updating those lines.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ghost picture ghost  路  3Comments

RomainSauvaire picture RomainSauvaire  路  3Comments

Fuzzyma picture Fuzzyma  路  3Comments

kerbylav picture kerbylav  路  3Comments

JamborJan picture JamborJan  路  3Comments