add check exist "this.placeholder[0].parentNode"

this.placeholder[0].parentNode is sometine null or undefined. so add code that check exist parentnode.
It's same as line 497