Don't reference console in places where it might not exist.