import { assert } from "../../../assert.js";
import { array_remove_first } from "../../../collection/array/array_remove_first.js";

/**
 *
 * @param {TopoMesh} mesh
 * @param {TopoVertex} vertex
 */
export function tm_kill_only_vert(mesh, vertex) {
    assert.equal(vertex.isTopoVertex, true, "v.isTopoVertex !== true");
    assert.arrayHas(mesh.vertices, vertex, 'element not found');

    array_remove_first(mesh.vertices, vertex);
}
