added node searching function