removing flatten