Fixed bug where tabs werent getting deleted