fix spelling and window emit calls