Code Duplication    Length = 4-4 lines in 2 locations

core/db_models/EEM_Event.model.php 2 locations

@@ 592-595 (lines=4) @@
589
            'Datetime.DTT_EVT_end' => array('<', EEM_Datetime::instance()->current_time_for_query('DTT_EVT_end')),
590
            'EVT_ID'               => array('NOT IN', $event_ids),
591
        );
592
        if (isset($where_params['OR'])) {
593
            $and_condition['OR'] = $where_params['OR'];
594
            unset($where_params['OR']);
595
        }
596
        if (isset($where_params['Datetime.DTT_EVT_end'])) {
597
            $and_condition['Datetime.DTT_EVT_end****'] = $where_params['Datetime.DTT_EVT_end'];
598
            unset($where_params['Datetime.DTT_EVT_end']);
@@ 638-641 (lines=4) @@
635
        }
636
        // if we have any additional query_params, let's add them to the 'AND' condition
637
        $where_params['AND']['status'] = array('!=', 'publish');
638
        if (isset($where_params['OR'])) {
639
            $where_params['AND']['OR'] = $where_params['OR'];
640
            unset($where_params['OR']);
641
        }
642
        if (isset($where_params['Datetime.DTT_EVT_end'])) {
643
            $where_params['AND']['Datetime.DTT_EVT_end****'] = $where_params['Datetime.DTT_EVT_end'];
644
            unset($where_params['Datetime.DTT_EVT_end']);