Code Duplication    Length = 11-11 lines in 3 locations

plugin/bbb/lib/bbb.lib.php 3 locations

@@ 338-348 (lines=11) @@
335
        while ($status === false) {
336
337
            $meetingIsRunningInfo = $this->getMeetingInfo($params);
338
            if ($meetingIsRunningInfo === false) {
339
                //checking with the remote_id didn't work, so just in case and
340
                // to provide backwards support, check with the id
341
                $params = array(
342
                    'meetingId' => $meetingData['id'],
343
                    //  -- REQUIRED - The unique id for the meeting
344
                    'password' => $this->getModMeetingPassword()
345
                    //  -- REQUIRED - The moderator password for the meeting
346
                );
347
                $meetingIsRunningInfo = $this->getMeetingInfo($params);
348
            }
349
350
            if ($this->debug) {
351
                error_log(print_r($meetingIsRunningInfo, 1));
@@ 465-475 (lines=11) @@
462
        $item = array();
463
        foreach ($meetingList as $meetingDB) {
464
            $meetingBBB = $this->getMeetingInfo(['meetingId' => $meetingDB['remote_id'], 'password' => $pass]);
465
            if ($meetingBBB === false) {
466
                //checking with the remote_id didn't work, so just in case and
467
                // to provide backwards support, check with the id
468
                $params = array(
469
                    'meetingId' => $meetingDB['id'],
470
                    //  -- REQUIRED - The unique id for the meeting
471
                    'password' => $pass
472
                    //  -- REQUIRED - The moderator password for the meeting
473
                );
474
                $meetingBBB = $this->getMeetingInfo($params);
475
            }
476
477
            if ($meetingDB['visibility'] == 0 && $this->isConferenceManager() === false) {
478
                continue;
@@ 818-828 (lines=11) @@
815
        }
816
        $pass = $this->getModMeetingPassword();
817
        $info = $this->getMeetingInfo(array('meetingId' => $meetingData['remote_id'], 'password' => $pass));
818
        if ($info === false) {
819
            //checking with the remote_id didn't work, so just in case and
820
            // to provide backwards support, check with the id
821
            $params = array(
822
                'meetingId' => $meetingData['id'],
823
                //  -- REQUIRED - The unique id for the meeting
824
                'password' => $pass
825
                //  -- REQUIRED - The moderator password for the meeting
826
            );
827
            $info = $this->getMeetingInfo($params);
828
        }
829
830
        if (!empty($info) && isset($info['participantCount'])) {
831
            return $info['participantCount'];