added arg flags where appropriate