]> source.dussan.org Git - nextcloud-server.git/commitdiff
Always send a POST body
authorRobin Appelman <icewind@owncloud.com>
Fri, 13 Jun 2014 13:28:35 +0000 (15:28 +0200)
committerBjoern Schiessle <schiessle@owncloud.com>
Sat, 14 Jun 2014 08:22:38 +0000 (10:22 +0200)
apps/files_sharing/lib/external/scanner.php

index 8fb8683ed922361768f351a97589020f89abc264..7381450521ef3f2ec3d59d4131d3f63cbb25d0b6 100644 (file)
@@ -28,10 +28,8 @@ class Scanner extends \OC\Files\Cache\Scanner {
 
                curl_setopt($ch, CURLOPT_URL, $url);
                curl_setopt($ch, CURLOPT_POST, 1);
-               if ($password) {
-                       curl_setopt($ch, CURLOPT_POSTFIELDS,
-                               http_build_query(array('password' => $password)));
-               }
+               curl_setopt($ch, CURLOPT_POSTFIELDS,
+                       http_build_query(array('password' => $password)));
                curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
 
                $result = curl_exec($ch);