fix tab deleting