Add check for invalid xhr object in ExtJS listener

Sometimes ExtJS will pass a bogus XHR object (during file upload requests) that doesn't contain a `getResponseHeader` method - checking for it beforehand will prevent a hard error from occurring.
Merge pull request #17 from voithos/patch-1

Add check for invalid xhr object in ExtJS listener