fix if file is not yet created
This commit is contained in:
parent
8f963b95e5
commit
c0c4fe5fd3
1 changed files with 7 additions and 2 deletions
|
@ -131,8 +131,13 @@ class Proxy extends \OC_FileProxy {
|
|||
$encData = Crypt::symmetricEncryptFileContent( $data, $plainKey );
|
||||
|
||||
$sharingEnabled = \OCP\Share::isEnabled();
|
||||
|
||||
$uniqueUserIds = $util->getSharingUsersArray( $sharingEnabled, $filePath, $userId );
|
||||
|
||||
// if file exists try to get sharing users
|
||||
if($view->file_exists($path)) {
|
||||
$uniqueUserIds = $util->getSharingUsersArray( $sharingEnabled, $filePath, $userId );
|
||||
} else {
|
||||
$uniqueUserIds[] = $userId;
|
||||
}
|
||||
|
||||
// Fetch public keys for all users who will share the file
|
||||
$publicKeys = Keymanager::getPublicKeys( $view, $uniqueUserIds );
|
||||
|
|
Loading…
Reference in a new issue