- nodes_to_delete = node_ids - node_ids_not_to_delete
-
- # update the visibility etc on the current nodes
- update_time = Time.now()
-
- Node.update(node_ids_to_delete, {:user_id = user.id, :timestamp => update_time, :visibility => false})
-
- # create old nodes