Using 'setInterval' better in case when 'editor.document' is long or editor has to many 'CKEDITOR.editor.dataFiltered' rules.
As a result 'editor.document.getBody()' could not be exist at 'observer.observe()' call time, nothing to observe.
'setInterval' is kinde of listener, which waits until 'editor.document' becomes an object and after that 'observer.observe()' will be called.