implement fetch next leaf behavior