Replaced fix for stage env.
Added extra condition to check if stage in url.