added timeout to XHR request