diff options
author | Alexander <iam.asm89@gmail.com> | 2012-07-15 17:46:50 +0200 |
---|---|---|
committer | Alexander <iam.asm89@gmail.com> | 2013-01-07 20:58:58 +0100 |
commit | cd47f40584b192f6bc94e48dfbe7545280f382c9 (patch) | |
tree | 52a319948dd2a71e50e811c932d3f8d41a0218cd /Core/Exception/UsernameNotFoundException.php | |
parent | 2a58d99772d05834fb6687268d49f256e55df4bb (diff) | |
download | symfony-security-cd47f40584b192f6bc94e48dfbe7545280f382c9.zip symfony-security-cd47f40584b192f6bc94e48dfbe7545280f382c9.tar.gz symfony-security-cd47f40584b192f6bc94e48dfbe7545280f382c9.tar.bz2 |
[Security] Fix `AuthenticationException` serialization
Diffstat (limited to 'Core/Exception/UsernameNotFoundException.php')
-rw-r--r-- | Core/Exception/UsernameNotFoundException.php | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/Core/Exception/UsernameNotFoundException.php b/Core/Exception/UsernameNotFoundException.php index 421fada..9a9989f 100644 --- a/Core/Exception/UsernameNotFoundException.php +++ b/Core/Exception/UsernameNotFoundException.php @@ -48,4 +48,27 @@ class UsernameNotFoundException extends AuthenticationException { $this->username = $username; } + + /** + * {@inheritDoc} + */ + public function serialize() + { + return serialize(array( + $this->username, + parent::serialize(), + )); + } + + /** + * {@inheritDoc} + */ + public function unserialize($str) + { + list( + $this->username, + $parentData + ) = unserialize($str); + parent::unserialize($parentData); + } } |