Fixed the editing bug