diff options
author | Mario <mario@mariovavti.com> | 2022-02-11 09:21:19 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2022-02-11 09:21:19 +0000 |
commit | 6d8aabab2347feabdd804b609dcd4513f09f78d4 (patch) | |
tree | 9bea1aba6caa85084ec664f498c445bb92d9457c /vendor/sabre/dav/lib/DAV/Xml | |
parent | e74359fcfe4d97efe72a811b45526a69edae3893 (diff) | |
download | volse-hubzilla-6d8aabab2347feabdd804b609dcd4513f09f78d4.tar.gz volse-hubzilla-6d8aabab2347feabdd804b609dcd4513f09f78d4.tar.bz2 volse-hubzilla-6d8aabab2347feabdd804b609dcd4513f09f78d4.zip |
composer libs minor version updates
Diffstat (limited to 'vendor/sabre/dav/lib/DAV/Xml')
-rw-r--r-- | vendor/sabre/dav/lib/DAV/Xml/Element/Response.php | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/vendor/sabre/dav/lib/DAV/Xml/Element/Response.php b/vendor/sabre/dav/lib/DAV/Xml/Element/Response.php index 45c161fa4..79f06a09b 100644 --- a/vendor/sabre/dav/lib/DAV/Xml/Element/Response.php +++ b/vendor/sabre/dav/lib/DAV/Xml/Element/Response.php @@ -121,7 +121,7 @@ class Response implements Element foreach ($this->getResponseProperties() as $status => $properties) { // Skipping empty lists - if (!$properties || (!ctype_digit($status) && !is_int($status))) { + if (!$properties || (!is_int($status) && !ctype_digit($status))) { continue; } $empty = false; @@ -186,8 +186,21 @@ class Response implements Element return []; } + + if (!$reader->read()) { + $reader->next(); + + return []; + } + + if (Reader::END_ELEMENT === $reader->nodeType) { + $reader->next(); + + return []; + } + $values = []; - $reader->read(); + do { if (Reader::ELEMENT === $reader->nodeType) { $clark = $reader->getClark(); @@ -199,9 +212,12 @@ class Response implements Element $values[$clark] = $reader->parseCurrentElement()['value']; } } else { - $reader->read(); + if (!$reader->read()) { + break; + } } } while (Reader::END_ELEMENT !== $reader->nodeType); + $reader->read(); return $values; |