changed to new insertNode method