No restricted globals September 22, 2022 by Tarik Try adding window before location (i.e. window.location).