Make xhr backend to js-github more robust.