Sim
Well-known member
- Affected version
- 2.3.0
In v2.3.0 beta 6 I believe
The issue is that the way this has been implmented breaks certain systems - particularly my unit test framework - because it is simply "including" the file with no protection for redeclaration of functions contained within.
Please add protection from function redeclaration - as contained in the original
For example:
I have verified that protecting the function declarations in this manner allows my unit test framework to operate as expected.
src/vendor/dokuwiki/utf8/utf8.php
was replaced by src/utf8.php
acting as a shim for the new XF\Util\Str
functions.The issue is that the way this has been implmented breaks certain systems - particularly my unit test framework - because it is simply "including" the file with no protection for redeclaration of functions contained within.
Please add protection from function redeclaration - as contained in the original
src/vendor/dokuwiki/utf8/utf8.php
For example:
PHP:
if(!function_exists('utf8_isASCII')){
function utf8_isASCII(string $str): string { return Str::is_ascii($str); }
}
I have verified that protecting the function declarations in this manner allows my unit test framework to operate as expected.