switched relative urls to window.location.origin (need to fix the root cause of this BS)