Tribe__Validate::options()

validates fields that have options (radios, dropdowns, etc.) by making sure the value is part of the options array


Source

File: src/Tribe/Validate.php

		public function options() {
			if ( array_key_exists( $this->value, $this->field['options'] ) ) {
				$this->value         = ( $this->value === 0 ) ? false : $this->value;
				$this->result->valid = true;
			} else {
				$this->result->valid = false;
				$this->result->error = sprintf( esc_html__( "%s must have a value that's part of its options.", 'tribe-common' ), $this->label );
			}
		}