From 129b8154fbde42ffbe16c25b761e9bc16bd7eac0 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Sat, 21 Jan 2012 20:45:31 +0530 Subject: [PATCH] dont fail if no error events are bound --- source/Ox.UI/js/Core/Ox.Request.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/Ox.UI/js/Core/Ox.Request.js b/source/Ox.UI/js/Core/Ox.Request.js index 7600c3b9..85fa8e2b 100644 --- a/source/Ox.UI/js/Core/Ox.Request.js +++ b/source/Ox.UI/js/Core/Ox.Request.js @@ -185,7 +185,7 @@ Ox.Request = (function() { }; callback(data); } else { - $element.triggerEvent('error', data); + $element && $element.triggerEvent('error', data); } pending[options.id] = false; }