Fix whitespace and file action cleanup

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2018-11-20 12:20:06 +01:00 committed by Roeland Jago Douma
parent fc99811d0a
commit 78056a3bef
No known key found for this signature in database
GPG Key ID: F941078878347C0C
3 changed files with 12 additions and 12 deletions

View File

@ -362,17 +362,16 @@
// remove previous
$tr.find('.action-menu').remove();
if (this.actions.length > 0) {
var $el = this._renderInlineAction({
name: 'menu',
displayName: '',
iconClass: 'icon-more',
altText: t('files', 'Actions'),
action: this._showMenuClosure
}, false, context);
var $el = this._renderInlineAction({
name: 'menu',
displayName: '',
iconClass: 'icon-more',
altText: t('files', 'Actions'),
action: this._showMenuClosure
}, false, context);
$el.addClass('permanent');
$el.addClass('permanent');
}
},
/**

View File

@ -209,7 +209,7 @@ OCA.Sharing.PublicApp = {
// Remove the link. This means that files without a default action fail hard
$tr.find('a.name').attr('href', '#');
delete this.fileActions.actions.all.Download;
this.fileActions.actions.all = {};
}
return $tr;
};
@ -299,6 +299,7 @@ OCA.Sharing.PublicApp = {
if (hideDownload === 'true') {
this.fileList.$el.find('#headerSelection').remove();
this.fileList.$el.find('.summary').find('td:first-child').remove();
}
}

View File

@ -114,7 +114,7 @@ describe('OC.Share.ShareDialogLinkShareView', function () {
$hideDownloadCheckbox = view.$el.find('.hideDownloadCheckbox');
expect($hideDownloadCheckbox.length).toBeFalsy();
expect($hideDownloadCheckbox.length).toBeTruthy();
});
it('checkbox is checked when the setting is enabled', function () {