instasent / sms-counter-php

SMS Counter and sanitize tools
MIT License
49 stars 28 forks source link

PHP 8 deprecations #23

Open Ang3 opened 2 years ago

Ang3 commented 2 years ago

Describe the bug

PHP Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated (line 366 and 479).

https://github.com/instasent/sms-counter-php/blob/a0f017d6fa776a33e18a4e36257fb5d6453897ef/SMSCounter.php#L366 https://github.com/instasent/sms-counter-php/blob/a0f017d6fa776a33e18a4e36257fb5d6453897ef/SMSCounter.php#L479

To reproduce

Run the library on PHP8, then try to sanitize a value. You should have some deprecations.

(OPTIONAL) Additional context