many hours and just a few lines of code to fix deleting bug