Correcting bug in add window