Skip to content

Commit 40b380b

Browse files
committed
fix(files): Only render the menu if there are actions to show
Signed-off-by: Julius Härtl <[email protected]>
1 parent 5b7f81b commit 40b380b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

apps/files/js/fileactions.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -597,8 +597,8 @@
597597
Object.values = objectValues;
598598
}
599599

600-
var menuActions = Object.values(this.actions.all).filter(function (action) {
601-
return action.type !== OCA.Files.FileActions.TYPE_INLINE;
600+
var menuActions = Object.values(actions).filter(function (action) {
601+
return action.type !== OCA.Files.FileActions.TYPE_INLINE && (!defaultAction || action.name !== defaultAction.name)
602602
});
603603
// do not render the menu if nothing is in it
604604
if (menuActions.length > 0) {

0 commit comments

Comments
 (0)