resolved a bug in edit