Fix parentNode call