add another check for ga !== undefined