XHR request bugfix