fixed a bug where addevendialog wont close