summaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorBjörn Schießle <schiessle@owncloud.com>2016-04-18 17:15:20 +0200
committerBjörn Schießle <schiessle@owncloud.com>2016-04-20 17:47:33 +0200
commit2a6a336e873db394e9912de20478645f3e4b8fc4 (patch)
treea11034b3285296d9f679b903a2fe4fc52e453597 /core/js
parent2edbb7d4bd65db3aae4c2243da58c987087d32a8 (diff)
downloadnextcloud-server-2a6a336e873db394e9912de20478645f3e4b8fc4.tar.gz
nextcloud-server-2a6a336e873db394e9912de20478645f3e4b8fc4.zip
always share with same default permissions, no special handling for remote shares
Diffstat (limited to 'core/js')
-rw-r--r--core/js/shareitemmodel.js26
1 files changed, 11 insertions, 15 deletions
diff --git a/core/js/shareitemmodel.js b/core/js/shareitemmodel.js
index 2d4af365114..3ced66a1a78 100644
--- a/core/js/shareitemmodel.js
+++ b/core/js/shareitemmodel.js
@@ -154,21 +154,17 @@
// Default permissions are Edit (CRUD) and Share
// Check if these permissions are possible
var permissions = OC.PERMISSION_READ;
- if (shareType === OC.Share.SHARE_TYPE_REMOTE) {
- permissions = OC.PERMISSION_CREATE | OC.PERMISSION_UPDATE | OC.PERMISSION_READ;
- } else {
- if (this.updatePermissionPossible()) {
- permissions = permissions | OC.PERMISSION_UPDATE;
- }
- if (this.createPermissionPossible()) {
- permissions = permissions | OC.PERMISSION_CREATE;
- }
- if (this.deletePermissionPossible()) {
- permissions = permissions | OC.PERMISSION_DELETE;
- }
- if (this.configModel.get('isResharingAllowed') && (this.sharePermissionPossible())) {
- permissions = permissions | OC.PERMISSION_SHARE;
- }
+ if (this.updatePermissionPossible()) {
+ permissions = permissions | OC.PERMISSION_UPDATE;
+ }
+ if (this.createPermissionPossible()) {
+ permissions = permissions | OC.PERMISSION_CREATE;
+ }
+ if (this.deletePermissionPossible()) {
+ permissions = permissions | OC.PERMISSION_DELETE;
+ }
+ if (this.configModel.get('isResharingAllowed') && (this.sharePermissionPossible())) {
+ permissions = permissions | OC.PERMISSION_SHARE;
}
attributes.permissions = permissions;