From f56e09d49e4e6ffce2c3cfbd8186ad1b8ae05e05 Mon Sep 17 00:00:00 2001 From: Michael Aerni Date: Tue, 9 Jul 2024 16:05:04 -0400 Subject: [PATCH] Fix wrong variable type check (#162) --- src/Fieldtypes/SourceFieldtype.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Fieldtypes/SourceFieldtype.php b/src/Fieldtypes/SourceFieldtype.php index c93325bd..1216b252 100755 --- a/src/Fieldtypes/SourceFieldtype.php +++ b/src/Fieldtypes/SourceFieldtype.php @@ -84,7 +84,7 @@ public function augment(mixed $data): mixed if ($data === '@default') { $value = $this->sourceFieldtype()->augment($this->defaultValueFromCascade()); - return is_string($data) && Str::contains($value, '@field') + return is_string($value) && Str::contains($value, '@field') ? $this->sourceFieldtype()->augment($this->parseFieldValues($value)) : $value; }