From 44edf1fc75486709eb84f8e595df4e72925ef0a7 Mon Sep 17 00:00:00 2001 From: eileen Date: Tue, 20 Nov 2018 16:50:06 +1300 Subject: [PATCH] dev/core#406 fix warnings under php 7.2 when importing --- CRM/Contact/Import/Parser/Contact.php | 28 +++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/CRM/Contact/Import/Parser/Contact.php b/CRM/Contact/Import/Parser/Contact.php index 420cb70de2..6dcfa65253 100644 --- a/CRM/Contact/Import/Parser/Contact.php +++ b/CRM/Contact/Import/Parser/Contact.php @@ -37,8 +37,8 @@ require_once 'api/v3/utils.php'; * class to parse contact csv files */ class CRM_Contact_Import_Parser_Contact extends CRM_Contact_Import_Parser { - protected $_mapperKeys; - protected $_mapperLocType; + protected $_mapperKeys = []; + protected $_mapperLocType = []; protected $_mapperPhoneType; protected $_mapperImProvider; protected $_mapperWebsiteType; @@ -109,21 +109,21 @@ class CRM_Contact_Import_Parser_Contact extends CRM_Contact_Import_Parser { * Class constructor. * * @param array $mapperKeys - * @param int $mapperLocType - * @param int $mapperPhoneType - * @param int $mapperImProvider - * @param int $mapperRelated - * @param int $mapperRelatedContactType + * @param array $mapperLocType + * @param array $mapperPhoneType + * @param array $mapperImProvider + * @param array $mapperRelated + * @param array $mapperRelatedContactType * @param array $mapperRelatedContactDetails - * @param int $mapperRelatedContactLocType - * @param int $mapperRelatedContactPhoneType - * @param int $mapperRelatedContactImProvider - * @param int $mapperWebsiteType - * @param int $mapperRelatedContactWebsiteType + * @param array $mapperRelatedContactLocType + * @param array $mapperRelatedContactPhoneType + * @param array $mapperRelatedContactImProvider + * @param array $mapperWebsiteType + * @param array $mapperRelatedContactWebsiteType */ public function __construct( - &$mapperKeys, $mapperLocType = NULL, $mapperPhoneType = NULL, $mapperImProvider = NULL, $mapperRelated = NULL, $mapperRelatedContactType = NULL, $mapperRelatedContactDetails = NULL, $mapperRelatedContactLocType = NULL, $mapperRelatedContactPhoneType = NULL, $mapperRelatedContactImProvider = NULL, - $mapperWebsiteType = NULL, $mapperRelatedContactWebsiteType = NULL + &$mapperKeys, $mapperLocType = [], $mapperPhoneType = [], $mapperImProvider = [], $mapperRelated = [], $mapperRelatedContactType = [], $mapperRelatedContactDetails = [], $mapperRelatedContactLocType = [], $mapperRelatedContactPhoneType = [], $mapperRelatedContactImProvider = [], + $mapperWebsiteType = [], $mapperRelatedContactWebsiteType = [] ) { parent::__construct(); $this->_mapperKeys = &$mapperKeys; -- 2.25.1