fix delete machine bug