Skip to content

Commit 4c32bf8

Browse files
committed
formatting
1 parent aff3151 commit 4c32bf8

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/Illuminate/Database/Eloquent/Casts/AsEncryptedArrayObject.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public function get($model, $key, $value, $attributes)
2929

3030
public function set($model, $key, $value, $attributes)
3131
{
32-
if ($value !== null) {
32+
if (! is_null($value)) {
3333
return [$key => Crypt::encryptString(json_encode($value))];
3434
}
3535

@@ -38,7 +38,7 @@ public function set($model, $key, $value, $attributes)
3838

3939
public function serialize($model, string $key, $value, array $attributes)
4040
{
41-
return $value !== null ? $value->getArrayCopy() : null;
41+
return ! is_null($value) ? $value->getArrayCopy() : null;
4242
}
4343
};
4444
}

src/Illuminate/Database/Eloquent/Casts/AsEncryptedCollection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function get($model, $key, $value, $attributes)
3030

3131
public function set($model, $key, $value, $attributes)
3232
{
33-
if ($value !== null) {
33+
if (! is_null($value)) {
3434
return [$key => Crypt::encryptString(json_encode($value))];
3535
}
3636

0 commit comments

Comments
 (0)