DataPacket: fixed var_dump() not showing private & protected subclass properties

This commit is contained in:
Dylan K. Taylor 2019-11-11 15:41:08 +00:00
parent 025cb73bf5
commit 8d2e3894ef

View File

@ -143,7 +143,7 @@ abstract class DataPacket extends NetworkBinaryStream{
public function __debugInfo(){
$data = [];
foreach($this as $k => $v){
foreach((array) $this as $k => $v){
if($k === "buffer" and is_string($v)){
$data[$k] = bin2hex($v);
}elseif(is_string($v) or (is_object($v) and method_exists($v, "__toString"))){