add current depth of node helper