diff options
author | Bart Visscher <bartv@thisnet.nl> | 2013-06-28 06:18:56 -0700 |
---|---|---|
committer | Bart Visscher <bartv@thisnet.nl> | 2013-06-28 06:18:56 -0700 |
commit | 6ddfe2029c8db19ae1779915b9c14836bbbabcd0 (patch) | |
tree | a520affb75570d72e6638ab8d147d56e6199a2aa /lib | |
parent | df9e56efd0652665a653a0f83ec3628f4e14f579 (diff) | |
parent | 5d51118cb2648b37cfcb938e74756588025046cf (diff) | |
download | nextcloud-server-6ddfe2029c8db19ae1779915b9c14836bbbabcd0.tar.gz nextcloud-server-6ddfe2029c8db19ae1779915b9c14836bbbabcd0.zip |
Merge pull request #3865 from owncloud/fix_test_for_oracle
Fix sharing test for oracle
Diffstat (limited to 'lib')
-rw-r--r-- | lib/public/share.php | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/lib/public/share.php b/lib/public/share.php index 122ab3fa030..a98cfda2089 100644 --- a/lib/public/share.php +++ b/lib/public/share.php @@ -963,6 +963,30 @@ class Share { $switchedItems = array(); $mounts = array(); while ($row = $result->fetchRow()) { + if (isset($row['id'])) { + $row['id']=(int)$row['id']; + } + if (isset($row['share_type'])) { + $row['share_type']=(int)$row['share_type']; + } + if (isset($row['parent'])) { + $row['parent']=(int)$row['parent']; + } + if (isset($row['file_parent'])) { + $row['file_parent']=(int)$row['file_parent']; + } + if (isset($row['file_source'])) { + $row['file_source']=(int)$row['file_source']; + } + if (isset($row['permissions'])) { + $row['permissions']=(int)$row['permissions']; + } + if (isset($row['storage'])) { + $row['storage']=(int)$row['storage']; + } + if (isset($row['stime'])) { + $row['stime']=(int)$row['stime']; + } // Filter out duplicate group shares for users with unique targets if ($row['share_type'] == self::$shareTypeGroupUserUnique && isset($items[$row['parent']])) { $row['share_type'] = self::SHARE_TYPE_GROUP; @@ -978,7 +1002,7 @@ class Share { // Check if the same owner shared with the user twice // through a group and user share - this is allowed $id = $targets[$row[$column]]; - if ($items[$id]['uid_owner'] == $row['uid_owner']) { + if (isset($items[$id]) && $items[$id]['uid_owner'] == $row['uid_owner']) { // Switch to group share type to ensure resharing conditions aren't bypassed if ($items[$id]['share_type'] != self::SHARE_TYPE_GROUP) { $items[$id]['share_type'] = self::SHARE_TYPE_GROUP; |