added some validations to orders