Fix bond deletion code