fixed bugs in stacked ae