renewed necc_nodes. Now it is kind of recursive function