Removed a bug when a line is removed