I was getting undefined appended to my http calls, this seemed to fix it (url.search was undefined, would concatenate undefined to end of url)