diff vendor/symfony/serializer/Normalizer/PropertyNormalizer.php @ 17:129ea1e6d783

Update, including to Drupal core 8.6.10
author Chris Cannam
date Thu, 28 Feb 2019 13:21:36 +0000
parents 1fec387a4317
children af1871eacc83
line wrap: on
line diff
--- a/vendor/symfony/serializer/Normalizer/PropertyNormalizer.php	Tue Jul 10 15:07:59 2018 +0100
+++ b/vendor/symfony/serializer/Normalizer/PropertyNormalizer.php	Thu Feb 28 13:21:36 2019 +0000
@@ -30,7 +30,7 @@
  */
 class PropertyNormalizer extends AbstractObjectNormalizer
 {
-    private $cache = array();
+    private $cache = [];
 
     /**
      * {@inheritdoc}
@@ -74,7 +74,7 @@
     /**
      * {@inheritdoc}
      */
-    protected function isAllowedAttribute($classOrObject, $attribute, $format = null, array $context = array())
+    protected function isAllowedAttribute($classOrObject, $attribute, $format = null, array $context = [])
     {
         if (!parent::isAllowedAttribute($classOrObject, $attribute, $format, $context)) {
             return false;
@@ -95,10 +95,10 @@
     /**
      * {@inheritdoc}
      */
-    protected function extractAttributes($object, $format = null, array $context = array())
+    protected function extractAttributes($object, $format = null, array $context = [])
     {
         $reflectionObject = new \ReflectionObject($object);
-        $attributes = array();
+        $attributes = [];
 
         do {
             foreach ($reflectionObject->getProperties() as $property) {
@@ -116,7 +116,7 @@
     /**
      * {@inheritdoc}
      */
-    protected function getAttributeValue($object, $attribute, $format = null, array $context = array())
+    protected function getAttributeValue($object, $attribute, $format = null, array $context = [])
     {
         try {
             $reflectionProperty = $this->getReflectionProperty($object, $attribute);
@@ -135,7 +135,7 @@
     /**
      * {@inheritdoc}
      */
-    protected function setAttributeValue($object, $attribute, $value, $format = null, array $context = array())
+    protected function setAttributeValue($object, $attribute, $value, $format = null, array $context = [])
     {
         try {
             $reflectionProperty = $this->getReflectionProperty($object, $attribute);