#FIX: modal dialog's submit function