[Pkg-owncloud-commits] [php-sabredav] 16/21: Fixed autoprefixing of dead {DAV:}href properties.
David Prévot
taffit at moszumanska.debian.org
Fri Jul 3 20:11:24 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository php-sabredav.
commit d84c856f0b4d671f30aca21816dbb33d23a5343d
Author: Evert Pot <me at evertpot.com>
Date: Thu Jul 2 17:12:18 2015 -0400
Fixed autoprefixing of dead {DAV:}href properties.
Fixes #680
---
CHANGELOG.md | 1 +
lib/DAV/Xml/Property/Href.php | 6 +++---
tests/Sabre/DAV/Xml/Element/PropTest.php | 2 +-
3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index a6d3f96..8cec28c 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,7 @@ ChangeLog
* #647: Postgres sql file fixes. (@davesouthney)
* #677: Resources with the name '0' would not get retrieved when using
`Depth: infinity` in a `PROPFIND` request.
+* #680: Fix 'autoprefixing' of dead `{DAV:}href` properties.
3.0.0 (2015-06-02)
diff --git a/lib/DAV/Xml/Property/Href.php b/lib/DAV/Xml/Property/Href.php
index e37f35c..246c965 100644
--- a/lib/DAV/Xml/Property/Href.php
+++ b/lib/DAV/Xml/Property/Href.php
@@ -145,8 +145,8 @@ class Href implements Element, HtmlOutput {
* Often you want to return an instance of the current class, but you are
* free to return other data as well.
*
- * Important note 2: You are responsible for advancing the reader to the
- * next element. Not doing anything will result in a never-ending loop.
+ * You are responsible for advancing the reader to the next element. Not
+ * doing anything will result in a never-ending loop.
*
* If you just want to skip parsing for this element altogether, you can
* just call $reader->next();
@@ -168,7 +168,7 @@ class Href implements Element, HtmlOutput {
}
if ($hrefs) {
- return new self($hrefs);
+ return new self($hrefs, false);
}
}
diff --git a/tests/Sabre/DAV/Xml/Element/PropTest.php b/tests/Sabre/DAV/Xml/Element/PropTest.php
index afa289a..f18b82d 100644
--- a/tests/Sabre/DAV/Xml/Element/PropTest.php
+++ b/tests/Sabre/DAV/Xml/Element/PropTest.php
@@ -63,7 +63,7 @@ XML;
XML;
$expected = [
- '{DAV:}foo' => new Href('/hello')
+ '{DAV:}foo' => new Href('/hello', false)
];
$elementMap = [
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabredav.git
More information about the Pkg-owncloud-commits
mailing list