if (property == null) {
throw new RuntimeException("Could not find property: " + propertyName);
}
// TODO remove all properties from all edges? I don't think so
Edge edge = graph.getEdge(edgeId, authorizations);
Object oldValue = null;
Property oldProperty = edge.getProperty(propertyKey, propertyName);
if (oldProperty != null) {
oldValue = oldProperty.getValue();
}
// TODO: replace "" when we implement commenting on ui
auditRepository.auditRelationshipProperty(AuditAction.DELETE, sourceId, destId, propertyKey, property.getDisplayName(),
oldValue, null, edge, "", "", user, lumifyVisibility.getVisibility());
edge.removeProperty(propertyKey, propertyName, authorizations);
graph.flush();
workQueueRepository.pushGraphPropertyQueue(edge, null, propertyName, workspaceId, null);
respondWithSuccessJson(response);