Code Duplication    Length = 7-8 lines in 2 locations

locallib.php 2 locations

@@ 220-226 (lines=7) @@
217
        $xml = bigbluebuttonbn_wrap_xml_load_file( bigbluebuttonbn_getRecordingsURL( $URL, $SALT, $meetingIDs ) );
218
    }
219
220
    if ( $xml && $xml->returncode == 'SUCCESS' && isset($xml->recordings) ) { //If there were meetings already created
221
        foreach ( $xml->recordings->recording as $recording ) {
222
            $recordings[] = bigbluebuttonbn_getRecordingArrayRow($recording);
223
        }
224
225
        usort($recordings, 'bigbluebuttonbn_recordingBuildSorter');
226
    }
227
228
    return $recordings;
229
}
@@ 246-253 (lines=8) @@
243
244
    $xml = bigbluebuttonbn_wrap_xml_load_file( bigbluebuttonbn_getRecordingsURL( $URL, $SALT, $meetingID ) );
245
246
    if ( $xml && $xml->returncode == 'SUCCESS' && isset($xml->recordings) ) { //If there were meetings already created
247
        foreach ($xml->recordings->recording as $recording) {
248
            if( $recording->recordID == $recordingID ) {
249
                $recordingArray = bigbluebuttonbn_getRecordingArrayRow($recording);
250
                break;
251
            }
252
        }
253
    }
254
255
    return $recordingArray;
256
}