protected function getResponseData($path, $default = null)
    {
        $array = $this->response;

        if (!empty($path)) {
            $keys = explode('.', $path);

            foreach ($keys as $key) {
                if (isset($array[$key])) {
                    $array = $array[$key];
                } else {
                    return $default;
                }
            }
        }

        return $array;
    }
protected function getResponseData($path, $default = null)
    {
        $array = $this->response;

        if (!empty($path)) {
            $keys = explode('.', $path);

            foreach ($keys as $key) {
                if (isset($array[$key])) {
                    $array = $array[$key];
                } else {
                    return $default;
                }
            }
        }

        return $array;
    }
protected function getResponseData ( $ path , $ default = null ) { $ array = $ this -> response ; if ( ! empty ( $ path ) ) { $ keys = explode ( '.' , $ path ) ; foreach ( $ keys as $ key ) { if ( isset ( $ array [ $ key ] ) ) { $ array = $ array [ $ key ] ; } else { return $ default ; } } } return $ array ; }
Attempts to pull value from array using dot notation.

@param string $path
@param string $default

@return mixed
Attempts to pull value from array using dot notation .