File tree Expand file tree Collapse file tree 1 file changed +17
-14
lines changed Expand file tree Collapse file tree 1 file changed +17
-14
lines changed Original file line number Diff line number Diff line change @@ -46,21 +46,24 @@ public function showObject(&$obj)
46
46
* @param int $indent
47
47
* @return string
48
48
*/
49
- public function debugObject ($ obj , $ indent = 0 )
49
+ public function debugObject ($ obj , int $ indent= 0 )
50
50
{
51
- if (is_array ($ obj )) {
52
- $ return = '' ;
53
- foreach ($ obj as $ k => $ v ) {
54
- $ return .= str_repeat (' ' , $ indent );
55
- if (is_array ($ v )) {
56
- $ return .= $ k . "->Array \n" ;
57
- $ return .= $ this ->debugObject ($ v , $ indent + 1 );
58
- } else {
59
- $ return .= $ k . "-> $ v \n" ;
60
- }
61
- }
62
- return $ return ;
63
- }
51
+ $ return = '' ;
52
+
53
+ if ( !is_array ($ obj ) ){
54
+ return $ return ;
55
+ }
56
+
57
+ foreach ($ obj as $ k => $ v ) {
58
+ $ return .= str_repeat (' ' , $ indent );
59
+ if (is_array ($ v )) {
60
+ $ return .= $ k . "->Array \n" ;
61
+ $ return .= $ this ->debugObject ($ v , $ indent + 1 );
62
+ } else {
63
+ $ return .= $ k . "-> $ v \n" ;
64
+ }
65
+ }
66
+ return $ return ;
64
67
}
65
68
66
69
public function nsRrDefined ($ query )
You can’t perform that action at this time.
0 commit comments