fixing doubleClickNode function