From 330e756282695c7a959b7c008296d906bbf2dc6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Thu, 24 Aug 2023 09:59:27 +0200 Subject: [PATCH] Fix doc and try to ignore phpstan warning --- htdocs/core/class/CSMSFile.class.php | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/htdocs/core/class/CSMSFile.class.php b/htdocs/core/class/CSMSFile.class.php index 58450de4d8e..d09a4413291 100644 --- a/htdocs/core/class/CSMSFile.class.php +++ b/htdocs/core/class/CSMSFile.class.php @@ -35,11 +35,26 @@ */ class CSMSFile { + /** + * @var DoliDB Database handler. + */ + public $db; + /** * @var string Error code (or message) */ public $error = ''; + /** + * @var string[] Array of Error code (or message) + */ + public $errors = array(); + + /** + * @var string end of line character + */ + public $eol; + public $addr_from; public $addr_to; public $deferred; @@ -124,8 +139,9 @@ class CSMSFile if (empty($conf->global->MAIN_DISABLE_ALL_SMS)) { // Action according to choosed sending method - if ($conf->global->MAIN_SMS_SENDMODE == 'ovh') { // Backward compatibility @deprecated + if (getDolGlobalString('MAIN_SMS_SENDMODE') == 'ovh') { // Backward compatibility @deprecated dol_include_once('/ovh/class/ovhsms.class.php'); + /** @phpstan-ignore-next-line */ $sms = new OvhSms($this->db); $sms->expe = $this->addr_from; $sms->dest = $this->addr_to;