From 748c13f4a72d8d70902836a0235870415c89979a Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Mon, 15 Dec 2014 13:13:39 -0500 Subject: [PATCH] Fixes broken test --- app/assets/javascripts/discourse/lib/keyboard_shortcuts.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js b/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js index 624a5431124..435d0724680 100644 --- a/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js +++ b/app/assets/javascripts/discourse/lib/keyboard_shortcuts.js @@ -190,7 +190,7 @@ Discourse.KeyboardShortcuts = Ember.Object.createWithMixins({ _bindToClick: function(selector, binding) { binding = binding.split(','); this.keyTrapper.bind(binding, function(e) { - e.preventDefault(); + if (e) { e.preventDefault(); } $(selector).click(); }); },