Remove unnecessary flags