fixed the bug wiht aggr tree