Consistified document.location and window.location + clean-up on creategroup widget