/**
  * Modifies the booking status if the event isn't free and also adds a filter to modify user feedback returned.
  * Triggered by the em_booking_add_yourgateway action.
  * @param EM_Event $EM_Event
  * @param EM_Booking $EM_Booking
  * @param boolean $post_validation
  */
 function booking_add($EM_Event, $EM_Booking, $post_validation = false)
 {
     global $wpdb, $wp_rewrite, $EM_Notices;
     //manual bookings
     if (!empty($_REQUEST['manual_booking']) && wp_verify_nonce($_REQUEST['manual_booking'], 'em_manual_booking_' . $_REQUEST['event_id'])) {
         //validate post
         if (!empty($_REQUEST['payment_amount']) && !is_numeric($_REQUEST['payment_amount'])) {
             $EM_Booking->add_error('Invalid payment amount, please provide a number only.', 'em-pro');
         }
         //add em_event_save filter to log transactions etc.
         add_filter('em_booking_save', array(&$this, 'em_booking_save'), 10, 2);
         //set flag that we're manually booking here, and set gateway to offline
         if (empty($_REQUEST['person_id']) || $_REQUEST['person_id'] < 0) {
             EM_Bookings::$force_registration = EM_Bookings::$disable_restrictions = true;
         }
     }
     parent::booking_add($EM_Event, $EM_Booking, $post_validation);
 }