From dc58c77f61e1e1cb197d2ed8a36b56c64abbe1a6 Mon Sep 17 00:00:00 2001 From: Matthew Thomas Date: Fri, 27 Apr 2018 10:45:24 +0100 Subject: [PATCH 1/2] Update entity_provider.rst Keep the array syntax consitant between the 2 serialization functions that are implemented --- security/entity_provider.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/security/entity_provider.rst b/security/entity_provider.rst index b339ad5ae92..c3606f19a09 100644 --- a/security/entity_provider.rst +++ b/security/entity_provider.rst @@ -112,13 +112,13 @@ with the following fields: ``id``, ``username``, ``password``, /** @see \Serializable::serialize() */ public function serialize() { - return serialize(array( + return serialize([ $this->id, $this->username, $this->password, // see section on salt below // $this->salt, - )); + ]); } /** @see \Serializable::unserialize() */ From 044b4b6b6fbfdb71049d11bf033684d256b6941f Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Tue, 3 Jul 2018 11:19:59 +0200 Subject: [PATCH 2/2] Fixed inconsistency differently --- security/entity_provider.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/security/entity_provider.rst b/security/entity_provider.rst index c3606f19a09..1fdb4501d1d 100644 --- a/security/entity_provider.rst +++ b/security/entity_provider.rst @@ -112,13 +112,13 @@ with the following fields: ``id``, ``username``, ``password``, /** @see \Serializable::serialize() */ public function serialize() { - return serialize([ + return serialize(array( $this->id, $this->username, $this->password, // see section on salt below // $this->salt, - ]); + )); } /** @see \Serializable::unserialize() */ @@ -130,7 +130,7 @@ with the following fields: ``id``, ``username``, ``password``, $this->password, // see section on salt below // $this->salt - ) = unserialize($serialized, ['allowed_classes' => false]); + ) = unserialize($serialized, array('allowed_classes' => false)); } }