summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/files_sharing/appinfo/update.php4
-rw-r--r--apps/files_sharing/lib/helper.php7
-rw-r--r--apps/files_sharing/lib/sharedstorage.php5
3 files changed, 9 insertions, 7 deletions
diff --git a/apps/files_sharing/appinfo/update.php b/apps/files_sharing/appinfo/update.php
index ebeeae10d2c..c79a2291e92 100644
--- a/apps/files_sharing/appinfo/update.php
+++ b/apps/files_sharing/appinfo/update.php
@@ -18,7 +18,7 @@ if (version_compare($installedVersion, '0.4', '<')) {
$users[] = $row['share_with'];
$shares[$row['id']] = $row['file_target'];
} else if ($row['share_type'] === "1" && ($row['item_type'] === 'file' || $row['item_type'] === 'folder')) {
- //collect all group sharesX
+ //collect all group shares
$users = array_merge($users, \OC_group::usersInGroup($row['share_with']));
$shares[$row['id']] = $row['file_target'];
} else if ($row['share_type'] === "2") {
@@ -48,7 +48,9 @@ if (version_compare($installedVersion, '0.4', '<')) {
$statement .= ' END WHERE `id` IN (' . $ids . ')';
$query = OCP\DB::prepare($statement);
+
$query->execute(array());
+
}
}
diff --git a/apps/files_sharing/lib/helper.php b/apps/files_sharing/lib/helper.php
index 1381c0002d3..e2780e98935 100644
--- a/apps/files_sharing/lib/helper.php
+++ b/apps/files_sharing/lib/helper.php
@@ -2,6 +2,9 @@
namespace OCA\Files_Sharing;
+use OC_Config;
+use PasswordHash;
+
class Helper {
/**
@@ -26,9 +29,6 @@ class Helper {
exit;
}
- $type = $linkItem['item_type'];
- $fileSource = $linkItem['file_source'];
- $shareOwner = $linkItem['uid_owner'];
$rootLinkItem = \OCP\Share::resolveReShare($linkItem);
$path = null;
if (isset($rootLinkItem['uid_owner'])) {
@@ -61,7 +61,6 @@ class Helper {
}
$basePath = $path;
- $rootName = basename($path);
if ($relativePath !== null && \OC\Files\Filesystem::isReadable($basePath . $relativePath)) {
$path .= \OC\Files\Filesystem::normalizePath($relativePath);
diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php
index eedd279bf2b..b8a799f720d 100644
--- a/apps/files_sharing/lib/sharedstorage.php
+++ b/apps/files_sharing/lib/sharedstorage.php
@@ -299,14 +299,14 @@ class Shared extends \OC\Files\Storage\Common {
}
/**
- * @brief rename a shared foder/file
+ * @brief rename a shared folder/file
* @param string $sourcePath
* @param string $targetPath
* @return bool
*/
private function renameMountPoint($sourcePath, $targetPath) {
- // it shoulbn't be possible to move a Shared storage into another one
+ // it shouldn't be possible to move a Shared storage into another one
list($targetStorage, ) = \OC\Files\Filesystem::resolvePath($targetPath);
if ($targetStorage instanceof \OC\Files\Storage\Shared) {
\OCP\Util::writeLog('file sharing',
@@ -452,6 +452,7 @@ class Shared extends \OC\Files\Storage\Common {
list($storage, $internalPath) = \OC\Files\Filesystem::resolvePath($source);
return $storage->free_space($internalPath);
}
+ return \OC\Files\SPACE_UNKNOWN;
}
public function getLocalFile($path) {