Skip to content

Commit

Permalink
Merge pull request #3 from call-learning/meetingsid
Browse files Browse the repository at this point in the history
Take into account several meetings ID when fetching recordings
  • Loading branch information
andrewnicols authored Sep 7, 2021
2 parents 92859e1 + 46f4297 commit f647b6b
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions application/src/Controller/ApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,11 +166,15 @@ public function recordingsGet(string $serverID, Request $request): XmlResponse
];

if ($request->query->has('meetingID') && $meetingID = $request->query->get('meetingID')) {
$meeting = $this->findRoomConfiguration($serverID, $meetingID);
if (empty($meeting)) {
return $this->handleRoomNotFound($meetingID);
$meetings = explode(',', $meetingID);
$filter['meeting'] = [];
foreach ($meetings as $mID) {
$meeting = $this->findRoomConfiguration($serverID, $mID);
if (empty($meeting)) {
return $this->handleRoomNotFound($mID);
}
$filter['meeting'][] = $meeting;
}
$filter['meeting'] = $meeting;
} else if ($request->query->has('recordID') && $recordID = $request->query->get('recordID')) {
$filter['recordID'] = explode(',', $recordID);
}
Expand Down

0 comments on commit f647b6b

Please sign in to comment.