Made tree dynamic.