summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/api.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/api.php b/lib/api.php
index 8d6bbb7cc09..12eea52d3b3 100644
--- a/lib/api.php
+++ b/lib/api.php
@@ -155,11 +155,11 @@ class OC_API {
// They may have failed for different reasons (different status codes)
// Which reponse code should we return?
// Maybe any that are not OC_API::RESPOND_SERVER_ERROR
- $response = $shipped['failed'][0];
+ $response = reset($shipped['failed']);
return $response;
} else {
// Return the third party failure result
- $response = $thirdparty['failed'][0];
+ $response = reset($thirdparty['failed']);
return $response;
}
// Merge the successful responses