corrected bug in dialogs