Code Duplication    Length = 7-8 lines in 2 locations

core/libraries/rest_api/ModelDataTranslator.php 2 locations

@@ 874-881 (lines=8) @@
871
            $requested_version = \EED_Core_Rest_Api::latest_rest_api_version();
872
        }
873
        $rest_query_params = $model_query_params;
874
        if (isset($model_query_params[0])) {
875
            $rest_query_params['where'] = ModelDataTranslator::prepareConditionsQueryParamsForRestApi(
876
                $model_query_params[0],
877
                $model,
878
                $requested_version
879
            );
880
            unset($rest_query_params[0]);
881
        }
882
        if (isset($model_query_params['having'])) {
883
            $rest_query_params['having'] = ModelDataTranslator::prepareConditionsQueryParamsForRestApi(
884
                $model_query_params['having'],
@@ 882-888 (lines=7) @@
879
            );
880
            unset($rest_query_params[0]);
881
        }
882
        if (isset($model_query_params['having'])) {
883
            $rest_query_params['having'] = ModelDataTranslator::prepareConditionsQueryParamsForRestApi(
884
                $model_query_params['having'],
885
                $model,
886
                $requested_version
887
            );
888
        }
889
        return apply_filters(
890
            'FHEE__EventEspresso\core\libraries\rest_api\Model_Data_Translator__prepare_query_params_for_rest_api',
891
            $rest_query_params,