Add error handling for fetching user summary

Includes changes to xhr.js to make it retry the connection in case of
timeout