Use window instead of this because it breaks if put into an IIFE with a modify context.