Skip to content

Commit c6c9342

Browse files
committed
fix: remove references to non-existent ShareTypes
A refactor was done to remove ShareTypes and an incomplete backport of 00c2b94 left incorrect references to shareTypes. Signed-off-by: nfebe <fenn25.fn@gmail.com>
1 parent 402e685 commit c6c9342

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

apps/files_sharing/src/components/SharingEntryLink.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -575,7 +575,7 @@ export default {
575575
* @return {Array}
576576
*/
577577
externalLinkActions() {
578-
const filterValidAction = (action) => (action.shareType.includes(ShareTypes.SHARE_TYPE_LINK) || action.shareType.includes(ShareTypes.SHARE_TYPE_EMAIL)) && !action.advanced
578+
const filterValidAction = (action) => (action.shareType.includes(ShareType.Link) || action.shareType.includes(ShareType.Email)) && !action.advanced
579579
// filter only the registered actions for said link
580580
return this.ExternalShareActions.actions
581581
.filter(filterValidAction)
@@ -620,7 +620,7 @@ export default {
620620
}
621621
622622
const shareDefaults = {
623-
share_type: ShareTypes.SHARE_TYPE_LINK,
623+
share_type: ShareType.Link,
624624
}
625625
if (this.config.isDefaultExpireDateEnforced) {
626626
// default is empty string if not set
@@ -708,7 +708,7 @@ export default {
708708
const path = (this.fileInfo.path + '/' + this.fileInfo.name).replace('//', '/')
709709
const options = {
710710
path,
711-
shareType: ShareTypes.SHARE_TYPE_LINK,
711+
shareType: ShareType.Link,
712712
password: share.password,
713713
expireDate: share.expireDate,
714714
attributes: JSON.stringify(this.fileInfo.shareAttributes),

apps/files_sharing/src/views/SharingDetailsTab.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,9 +342,9 @@ export default {
342342
switch (this.share.type) {
343343
case ShareType.User:
344344
return t('files_sharing', 'Share with {userName}', { userName: this.share.shareWithDisplayName })
345-
case this.SHARE_TYPES.SHARE_TYPE_EMAIL:
345+
case ShareType.Email:
346346
return t('files_sharing', 'Share with email {email}', { email: this.share.shareWith })
347-
case this.SHARE_TYPES.SHARE_TYPE_LINK:
347+
case ShareType.Link:
348348
return t('files_sharing', 'Share link')
349349
case ShareType.Group:
350350
return t('files_sharing', 'Share with group')

0 commit comments

Comments
 (0)