Skip to content

Commit

Permalink
Merge pull request #4 from Schlue/FRAMEWORK_6_0
Browse files Browse the repository at this point in the history
added __serialize
  • Loading branch information
ralflang committed Mar 28, 2024
2 parents 3abe630 + 0c44d91 commit f7bd337
Showing 1 changed file with 17 additions and 3 deletions.
20 changes: 17 additions & 3 deletions lib/Horde/Smtp.php
Expand Up @@ -218,19 +218,33 @@ public function __clone()
{
throw new LogicException('Object cannot be cloned.');
}

/**
*/
public function serialize()
{
return serialize($this->_params);
return serialize($this->__serialize());
}

/**
*/
public function unserialize($data)
{
$this->_params = @unserialize($data);
$this->__unserialize(unserialize($data));
}

/**
* @return array
*/
public function __serialize()
{
return $this->_params;
}

/**
*/
public function __unserialize(array $data)
{
$this->_params = $data;
$this->_initOb();
}

Expand Down

0 comments on commit f7bd337

Please sign in to comment.