Adding support for 'tree complete' callback
Refactoring ->set() validation