Code Duplication    Length = 7-7 lines in 2 locations

core/libraries/rest_api/controllers/model/Read.php 2 locations

@@ 1247-1253 (lines=7) @@
1244
    public function createModelQueryParams($model, $query_params)
1245
    {
1246
        $model_query_params = array();
1247
        if (isset($query_params['where'])) {
1248
            $model_query_params[0] = ModelDataTranslator::prepareConditionsQueryParamsForModels(
1249
                $query_params['where'],
1250
                $model,
1251
                $this->getModelVersionInfo()->requestedVersion()
1252
            );
1253
        }
1254
        if (isset($query_params['order_by'])) {
1255
            $order_by = $query_params['order_by'];
1256
        } elseif (isset($query_params['orderby'])) {
@@ 1284-1290 (lines=7) @@
1281
        if ($group_by !== null) {
1282
            $model_query_params['group_by'] = $group_by;
1283
        }
1284
        if (isset($query_params['having'])) {
1285
            $model_query_params['having'] = ModelDataTranslator::prepareConditionsQueryParamsForModels(
1286
                $query_params['having'],
1287
                $model,
1288
                $this->getModelVersionInfo()->requestedVersion()
1289
            );
1290
        }
1291
        if (isset($query_params['order'])) {
1292
            $model_query_params['order'] = $query_params['order'];
1293
        }