/**
  * simply validates the incoming message object and then sets up the properties for the messenger
  * @param  EE_Message $message
  * @throws EE_Error
  */
 protected function _validate_and_setup(EE_Message $message)
 {
     $template_pack = $message->get_template_pack();
     $variation = $message->get_template_pack_variation();
     //verify we have the required template pack value on the $message object.
     if (!$template_pack instanceof EE_Messages_Template_Pack) {
         throw new EE_Error(__('Incoming $message object must have an EE_Messages_Template_Pack object available.', 'event_espresso'));
     }
     $this->_tmp_pack = $template_pack;
     $this->_variation = $variation ? $variation : 'default';
     $template_fields = $this->get_template_fields();
     foreach ($template_fields as $template => $value) {
         if ($template !== 'extra') {
             $column_value = $message->get_field_or_extra_meta('MSG_' . $template);
             $message_template_value = $column_value ? $column_value : null;
             $this->_set_template_value($template, $message_template_value);
         }
     }
 }