Fixed bug with expansion where terminality occurs on the exact depth that check-on-expand takes effect