Allow to unset an asset attribute by specifying null (ie, ’defer’ => null)

This commit is contained in:
Djamil Legato
2021-06-03 15:51:24 -07:00
parent 39247ac7ef
commit c288d4bd0b

View File

@@ -156,6 +156,10 @@ trait AssetUtilsTrait
$no_key = ['loading'];
foreach ($this->attributes as $key => $value) {
if ($value === null) {
continue;
}
if (is_numeric($key)) {
$key = $value;
}