[Pkg-owncloud-commits] [owncloud] 48/63: Replace _method requirement by {g, s}etMethods()

David Prévot taffit at moszumanska.debian.org
Tue Dec 22 16:51:06 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch stable8.0
in repository owncloud.

commit 754ce336bb31aa70f9b06a9fac88a7bbe12aaf3d
Author: David Prévot <taffit at debian.org>
Date:   Sun Apr 19 12:55:07 2015 -0400

    Replace _method requirement by {g,s}etMethods()
    
    Git-Dch: Ignore
---
 ...lace-_method-requirement-by-g-s-etMethods.patch | 46 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 2 files changed, 47 insertions(+)

diff --git a/debian/patches/0010-Replace-_method-requirement-by-g-s-etMethods.patch b/debian/patches/0010-Replace-_method-requirement-by-g-s-etMethods.patch
new file mode 100644
index 0000000..b88ad70
--- /dev/null
+++ b/debian/patches/0010-Replace-_method-requirement-by-g-s-etMethods.patch
@@ -0,0 +1,46 @@
+From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit at debian.org>
+Date: Sun, 19 Apr 2015 12:00:58 -0400
+Subject: Replace `_method` requirement by {g,s}etMethods()
+MIME-Version: 1.0
+Content-Type: text/plain; charset="utf-8"
+Content-Transfer-Encoding: 8bit
+
+Make the call compatible with future Symfony version, and avoid
+E_USER_DEPRECATED as thrown by the current 2.7.0-beta1:
+
+The "_method" requirement is deprecated since version 2.2 and will be
+removed in 3.0. Use getMethods() instead. at
+…/Symfony/Component/Routing/Route.php#554
+
+The "_method" requirement is deprecated since version 2.2 and will be
+removed in 3.0. Use the setMethods() method instead or the "methods"
+option in the route definition. at
+…/Symfony/Component/Routing/Route.php#662
+
+Forwarded: https://github.com/owncloud/core/pull/15739
+---
+ lib/private/route/route.php | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/lib/private/route/route.php b/lib/private/route/route.php
+index 87030ad..7e8a169 100644
+--- a/lib/private/route/route.php
++++ b/lib/private/route/route.php
+@@ -19,7 +19,7 @@ class Route extends SymfonyRoute implements IRoute {
+ 	 * @return \OC\Route\Route
+ 	 */
+ 	public function method($method) {
+-		$this->setRequirement('_method', strtoupper($method));
++		$this->setMethods($method);
+ 		return $this;
+ 	}
+ 
+@@ -91,7 +91,7 @@ class Route extends SymfonyRoute implements IRoute {
+ 	 * @return \OC\Route\Route
+ 	 */
+ 	public function requirements($requirements) {
+-		$method = $this->getRequirement('_method');
++		$method = $this->getMethods();
+ 		$this->setRequirements($requirements);
+ 		if (isset($requirements['_method'])) {
+ 			$method = $requirements['_method'];
diff --git a/debian/patches/series b/debian/patches/series
index 8085f16..40ba465 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -7,3 +7,4 @@ path/0006-Adapt-google-api-php-client-path.patch
 path/0007-Adapt-Dropbox-path.patch
 0008-use-JSqueeze-instead-of-JSMin-13052.patch
 0009-updating-ZipStreamer.patch
+0010-Replace-_method-requirement-by-g-s-etMethods.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git



More information about the Pkg-owncloud-commits mailing list