added validations in posting swits