]> source.dussan.org Git - nextcloud-server.git/commitdiff
Only set the active item when there is one (not the case for quota)
authorJoas Schilling <coding@schilljs.com>
Fri, 9 Jun 2017 16:05:23 +0000 (18:05 +0200)
committerMorris Jobke <hey@morrisjobke.de>
Tue, 13 Jun 2017 17:27:59 +0000 (12:27 -0500)
Signed-off-by: Joas Schilling <coding@schilljs.com>
apps/files/js/navigation.js

index 83cd556c89afd41cb0519ff8a3274075262132e6..d213d0467b625d66d38a01921c604719dbf0f5f8 100644 (file)
                _onClickItem: function(ev) {
                        var $target = $(ev.target);
                        var itemId = $target.closest('li').attr('data-id');
-                       this.setActiveItem(itemId);
+                       if (!_.isUndefined(itemId)) {
+                               this.setActiveItem(itemId);
+                       }
                        ev.preventDefault();
                }
        };