You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
This is not really a bug in hidden-string library, I just wanted to point out that when xdebug extension is enabled, it simply ignores __debugInfo() and dumps HiddenString object. Consider the following snippet:
require_once realpath(dirname(__DIR__)) . '/vendor/autoload.php';
$hs = new \ParagonIE\HiddenString\HiddenString('some string');
var_dump($hs);
object(ParagonIE\HiddenString\HiddenString)#4 (2) {
["internalStringValue"]=>
string(1) "*"
["attention"]=>
string(82) "If you need the value of a HiddenString, invoke getString() instead of dumping it."
}
Maybe it's good idea to point out that in documentation, or better, just throw an exception if extension is enabled. Maintener
of Xdebug state's that this is intended behavior and won't be changed.
I know that this fact is pointed out in HiddenString::__debugInfo() method comments, but not everyone reads the code :)
The text was updated successfully, but these errors were encountered:
Hello,
This is not really a bug in
hidden-string
library, I just wanted to point out that when xdebug extension is enabled, it simply ignores__debugInfo()
and dumpsHiddenString
object. Consider the following snippet:Output with
xdebug
enabled:Output with
xdebug
disabled:Maybe it's good idea to point out that in documentation, or better, just throw an exception if extension is enabled. Maintener
of Xdebug state's that this is intended behavior and won't be changed.
I know that this fact is pointed out in
HiddenString::__debugInfo()
method comments, but not everyone reads the code :)The text was updated successfully, but these errors were encountered: