File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -327,8 +327,8 @@ public function prepend(Closure|array|null $prepend = null): static
327327
328328 if (is_array ($ this ->prepend ) && isset ($ this ->prepend ['name ' ], $ this ->prepend ['value ' ])) {
329329 $ this ->prepend ['value ' ] = (string ) $ this ->prepend ['value ' ];
330- } else if (is_null ($ this ->prepend )){
331- # Avoid throwing an exception in case $prepend is explicitly set to null, or a Closure evaluates to null.
330+ } elseif (is_null ($ this ->prepend )) {
331+ // Avoid throwing an exception in case $prepend is explicitly set to null, or a Closure evaluates to null.
332332 } else {
333333 throw new InvalidArgumentException ('The provided prepend value must be an array with "name" and "value" keys. ' );
334334 }
@@ -342,7 +342,7 @@ public function append(Closure|array|null $append = null): static
342342
343343 if (is_array ($ this ->append ) && isset ($ this ->append ['name ' ], $ this ->append ['value ' ])) {
344344 $ this ->append ['value ' ] = (string ) $ this ->append ['value ' ];
345- } else if (is_null ($ this ->append )) {
345+ } elseif (is_null ($ this ->append )) {
346346 // Avoid throwing an exception in case $append is explicitly set to null, or a Closure evaluates to null.
347347 } else {
348348 throw new \InvalidArgumentException ('The provided append value must be an array with "name" and "value" keys. ' );
@@ -356,6 +356,7 @@ public function getRelationship(): BelongsToMany|BelongsTo|null
356356 if (is_null ($ this ->relationship )) {
357357 return null ;
358358 }
359+
359360 return $ this ->getModelInstance ()->{$ this ->evaluate ($ this ->relationship )}();
360361 }
361362
You can’t perform that action at this time.
0 commit comments