void (Object element, @Nullable Object elementToPutNodeActionsFor, @NotNull Map<Object, List<NodeAction>> nodeActions) { List<NodeAction> actions = nodeActions.get(element); nodeActions.remove(element); if (elementToPutNodeActionsFor != null && actions != null) { nodeActions.put(elementToPutNodeActionsFor, actions); } }