fix error on passing null right node