Преглед на файлове

Fix federated link sharing permissions

If a link share has read permissions it may have too share permissions
(depending on whether federated shares are allowed or not). Therefore
the share permission needs to be ignored when checking the permissions
to determine the public upload status.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Daniel Calviño Sánchez преди 3 години
родител
ревизия
31d2d04c01
променени са 3 файла, в които са добавени 3 реда и са изтрити 1 реда
  1. 0 0
      core/js/dist/share_backend.js
  2. 0 0
      core/js/dist/share_backend.js.map
  3. 3 1
      core/js/sharedialoglinkshareview.js

Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
core/js/dist/share_backend.js


Файловите разлики са ограничени, защото са твърде много
+ 0 - 0
core/js/dist/share_backend.js.map


+ 3 - 1
core/js/sharedialoglinkshareview.js

@@ -882,7 +882,9 @@
 			var publicUploadRChecked = '';
 			var publicUploadWChecked = '';
 
-			switch (this.model.linkSharePermissions(share.id)) {
+			// Public upload status is independent of the share permission,
+			// which is used for federated shares.
+			switch (this.model.linkSharePermissions(share.id) & ~OC.PERMISSION_SHARE) {
 				case OC.PERMISSION_READ:
 					publicUploadRChecked = 'checked';
 					break;

Някои файлове не бяха показани, защото твърде много файлове са промени