mirror of
https://github.com/anikeen-com/id.git
synced 2026-03-15 14:46:15 +00:00
fix some issues
Signed-off-by: Maurice Preuß (envoyr) <hello@envoyr.com>
This commit is contained in:
@@ -2,21 +2,18 @@
|
||||
|
||||
namespace Anikeen\Id\Concerns;
|
||||
|
||||
use Anikeen\Id\Contracts\Billable;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
trait HasBillable
|
||||
{
|
||||
protected Billable|Model $billable;
|
||||
public mixed $billable;
|
||||
|
||||
public function setBillable(Billable|Model $billable): self
|
||||
public function setBillable(mixed $billable): self
|
||||
{
|
||||
$this->billable = $billable;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getBillable(): Billable|Model
|
||||
public function getBillable(): mixed
|
||||
{
|
||||
return $this->billable;
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@ trait HasParent
|
||||
{
|
||||
protected mixed $parent;
|
||||
|
||||
public function setParent($parent): self
|
||||
public function setParent(mixed $parent): self
|
||||
{
|
||||
$this->parent = $parent;
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ trait MagicProperties
|
||||
protected function setMagicProperties(stdClass $data): void
|
||||
{
|
||||
foreach ($data as $key => $value) {
|
||||
if (property_exists($this, $key)) {
|
||||
if (!property_exists($this, $key)) {
|
||||
$this->{$key} = $value;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user