diff options
author | Christophe Coevoet <stof@notk.org> | 2012-07-14 18:00:37 +0200 |
---|---|---|
committer | Christophe Coevoet <stof@notk.org> | 2012-07-14 18:00:37 +0200 |
commit | 671647a3a9fe3d13637f5db0f2bc411b9be0de2a (patch) | |
tree | ef3e6736ba9838584887595752a823bd3970cac9 | |
parent | f636a80f1f0fa4b8ff0ca390212bf89af14a07fb (diff) | |
download | symfony-security-671647a3a9fe3d13637f5db0f2bc411b9be0de2a.zip symfony-security-671647a3a9fe3d13637f5db0f2bc411b9be0de2a.tar.gz symfony-security-671647a3a9fe3d13637f5db0f2bc411b9be0de2a.tar.bz2 |
fixed the serialization of the SwitchUserRole
-rw-r--r-- | Core/Role/SwitchUserRole.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Core/Role/SwitchUserRole.php b/Core/Role/SwitchUserRole.php index c679584..3076f34 100644 --- a/Core/Role/SwitchUserRole.php +++ b/Core/Role/SwitchUserRole.php @@ -45,4 +45,22 @@ class SwitchUserRole extends Role { return $this->source; } + + /** + * {@inheritdoc} + */ + public function serialize() + { + return serialize(array(parent::serialize(), $this->source)); + } + + /** + * {@inheritdoc} + */ + public function unserialize($serialized) + { + list($parent, $this->source) = unserialize($serialized); + + parent::unserialize($parent); + } } |