#833: Allow to use core.Document.cloneNode

There was a bug when trying to use ´cloneNode´ on a document.


Was.