Code Duplication    Length = 5-5 lines in 2 locations

main/inc/lib/groupmanager.lib.php 1 location

@@ 1067-1071 (lines=5) @@
1064
            $sql .= " ORDER BY $column $direction";
1065
        }
1066
1067
        if (!empty($start) && !empty($limit)) {
1068
            $start = intval($start);
1069
            $limit = intval($limit);
1070
            $sql .= " LIMIT $start, $limit";
1071
        }
1072
        $res = Database::query($sql);
1073
        $users = array();
1074
        while ($obj = Database::fetch_object($res)) {

main/work/work.lib.php 1 location

@@ 4919-4923 (lines=5) @@
4916
        );
4917
    } else {
4918
        $limitString = null;
4919
        if (!empty($start) && !empty($limit)) {
4920
            $start = intval($start);
4921
            $limit = intval($limit);
4922
            $limitString = " LIMIT $start, $limit";
4923
        }
4924
4925
        $orderBy = null;
4926