Don't return error when just no sharing found

This commit is contained in:
Bart Visscher 2012-08-07 23:29:01 +02:00
parent 1e644b5a53
commit 1b5c8ff471

View file

@ -58,7 +58,7 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['item']
case 'getItemsSharedStatuses':
if (isset($_GET['itemType'])) {
$return = OCP\Share::getItemsShared($_GET['itemType'], OCP\Share::FORMAT_STATUSES);
($return) ? OC_JSON::success(array('data' => $return)) : OC_JSON::error();
is_array($return) ? OC_JSON::success(array('data' => $return)) : OC_JSON::error();
}
break;
case 'getItem':