Modify picknode fuction