update flash message for edit page