A better XMLHttpRequest2 wrapper