diff --git a/apps/files_sharing/ajax/getstatuses.php b/apps/files_sharing/ajax/getstatuses.php
index c1892e7e2a2149322f9bea3c462f8a1be190d892..8edcb214758ae78412f0fdb8894b4c25a32b4895 100644
--- a/apps/files_sharing/ajax/getstatuses.php
+++ b/apps/files_sharing/ajax/getstatuses.php
@@ -14,7 +14,7 @@ if ($rows = OC_Share::getMySharedItems()) {
 		$item = substr($source, $dirLength);
 		if ($rows[$i]['uid_shared_with'] == OC_Share::PUBLICLINK) {
 			$items[$item] = true;
-		} else {
+		} else if (!isset($items[$item])) {
 			$items[$item] = false;
 		}
 	}