Fix appendChild() for DOM elements. Fixes #107