summaryrefslogtreecommitdiff
path: root/framework/Web/Javascripts/extended
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web/Javascripts/extended')
-rw-r--r--framework/Web/Javascripts/extended/event.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/framework/Web/Javascripts/extended/event.js b/framework/Web/Javascripts/extended/event.js
index 4a35ba78..dd72d60e 100644
--- a/framework/Web/Javascripts/extended/event.js
+++ b/framework/Web/Javascripts/extended/event.js
@@ -16,7 +16,7 @@ Object.extend(Event, {
if (name == 'keypress' &&
((navigator.appVersion.indexOf('AppleWebKit') > 0)
- || element.attachEvent))
+ || (element && element.attachEvent)))
name = 'keydown';
this._observeAndCache(element, name, observer, useCapture);