fixes for edit mode