Fix svg not getting deleted