summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorBjörn Schießle <schiessle@owncloud.com>2013-02-22 16:02:27 +0100
committerBjörn Schießle <schiessle@owncloud.com>2013-02-22 16:02:27 +0100
commit40efeb91878e72eb5c2eb1ab50574cda9435e0fa (patch)
tree235cb16cb0795b268bf7e9d600a6e25f6abba135 /lib
parent2d267501a10642e5c601ca87748b692ca58e4094 (diff)
downloadnextcloud-server-40efeb91878e72eb5c2eb1ab50574cda9435e0fa.tar.gz
nextcloud-server-40efeb91878e72eb5c2eb1ab50574cda9435e0fa.zip
isSharedFile() doesn't detect all shares, just use getUsersSharingFile() directly either you get a list of users or not
Diffstat (limited to 'lib')
-rw-r--r--lib/public/share.php34
1 files changed, 0 insertions, 34 deletions
diff --git a/lib/public/share.php b/lib/public/share.php
index 720337c3c38..7630c8ae6cb 100644
--- a/lib/public/share.php
+++ b/lib/public/share.php
@@ -108,41 +108,7 @@ class Share {
return $path;
}
-
- public static function isSharedFile( $path ) {
-
- $fPath = self::prepFileTarget( $path );
-
- // Fetch all shares of this file path from DB
- $query = \OC_DB::prepare(
- 'SELECT
- id
- FROM
- `*PREFIX*share`
- WHERE
- file_target = ?'
- );
-
- $result = $query->execute( array( $fPath ) );
-
- if ( \OC_DB::isError( $result ) ) {
-
- \OC_Log::write( 'OCP\Share', \OC_DB::getErrorMessage( $result ) . ', path=' . $fPath, \OC_Log::ERROR );
-
- }
-
- if ( $result->fetchRow() !== false ) {
- return true;
-
- } else {
-
- return false;
-
- }
-
- }
-
/**
* @brief Find which users can access a shared item
* @param $path to the file