Code Duplication    Length = 3-3 lines in 2 locations

main/inc/lib/usermanager.lib.php 2 locations

@@ 1294-1296 (lines=3) @@
1291
                $sql_query .= "$field = '$value'";
1292
            }
1293
        }
1294
        if (count($order_by) > 0) {
1295
            $sql_query .= ' ORDER BY '.Database::escape_string(implode(',', $order_by), null, false);
1296
        }
1297
1298
        if (is_numeric($limit_from) && is_numeric($limit_from)) {
1299
            $limit_from = intval($limit_from);
@@ 1339-1341 (lines=3) @@
1336
                $sql_query .= implode(' '.$condition.' ', $temp_conditions);
1337
            }
1338
        }
1339
        if (count($order_by) > 0) {
1340
            $sql_query .= ' ORDER BY '.Database::escape_string(implode(',', $order_by), null, false);
1341
        }
1342
        $sql_result = Database::query($sql_query);
1343
        while ($result = Database::fetch_array($sql_result)) {
1344
            $return_array[] = $result;