Skip to content

Commit

Permalink
Changes to remove depreciation error for preg_replace function
Browse files Browse the repository at this point in the history
  • Loading branch information
msinghai committed May 12, 2024
1 parent 7c5056d commit 5a964c9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions protected/backend/components/ExtendedTaggable.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@ class ExtendedTaggable extends \dosamigos\taggable\Taggable
*/
public function afterSave($event)
{
if ($this->tagValues === null)
$tagNames = is_null($this->owner->{$this->attribute}) ? '': $this->owner->{$this->attribute};

if (is_null($this->tagValues))
{
$this->tagValues = $this->owner->{$this->attribute};
$this->tagValues = $tagNames;
}

if (!$this->owner->getIsNewRecord())
Expand Down

0 comments on commit 5a964c9

Please sign in to comment.