diff options
author | Robin Appelman <robin@icewind.nl> | 2018-09-03 19:13:22 +0200 |
---|---|---|
committer | Robin Appelman <robin@icewind.nl> | 2018-09-20 17:03:36 +0200 |
commit | a623e09868ce62c4f1773f7672e011e32bdf26d8 (patch) | |
tree | e001f1fe4318cf438eb5cd4590f377938d14a38d /build | |
parent | b4e452ad6025ab677bda49608803de1d84a59d11 (diff) | |
download | nextcloud-server-a623e09868ce62c4f1773f7672e011e32bdf26d8.tar.gz nextcloud-server-a623e09868ce62c4f1773f7672e011e32bdf26d8.zip |
remove old trashbin endpoint
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'build')
-rw-r--r-- | build/integration/features/bootstrap/Trashbin.php | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/build/integration/features/bootstrap/Trashbin.php b/build/integration/features/bootstrap/Trashbin.php index 49d547a5edc..81725e940d5 100644 --- a/build/integration/features/bootstrap/Trashbin.php +++ b/build/integration/features/bootstrap/Trashbin.php @@ -51,13 +51,17 @@ trait Trashbin { */ public function listTrashbinFolder($user, $path){ $this->asAn($user); - $params = '?dir=' . rawurlencode('/' . trim($path, '/')); - $this->sendingToWithDirectUrl('GET', '/index.php/apps/files_trashbin/ajax/list.php' . $params, null); + $this->sendingToWithDirectUrl('PROPFIND', "/remote.php/dav/trashbin/$user/$path", null); $this->theHTTPStatusCodeShouldBe('200'); - $response = json_decode($this->response->getBody(), true); - - return $response['data']['files']; + $body = $this->response->getBody(); + if($body && substr($body, 0, 1) === '<') { + $reader = new Sabre\Xml\Reader(); + $reader->xml($body); + return $reader->parse(); + } else { + return []; + } } /** |