Skip to content

Commit

Permalink
Recordings import: do not import locked recordings
Browse files Browse the repository at this point in the history
  • Loading branch information
flubshi committed Jun 26, 2024
1 parent 87057f9 commit 3b94b3c
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/WaipuData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1731,11 +1731,16 @@ PVR_ERROR WaipuData::GetRecordings(bool deleted, kodi::addon::PVRRecordingsResul
if (recordingEntry.HasMember("recordingGroup") && recordingEntry["recordingGroup"].IsInt())
{
int recordingGroup = recordingEntry["recordingGroup"].GetInt();
kodi::Log(ADDON_LOG_DEBUG, "[recordings] found group: %i;", recordingGroup);
kodi::Log(ADDON_LOG_DEBUG, "[%s] found group: %i;", __FUNCTION__, recordingGroup);
recordingGroups.insert(recordingGroup);
}
else if (status == "FINISHED" || status == "RECORDING")
{
if (recordingEntry.HasMember("locked") && recordingEntry["locked"].GetBool())
{
kodi::Log(ADDON_LOG_DEBUG, "[%s] Skip locked recording", __FUNCTION__);
continue;
}
recordings_count++;
results.Add(ParseRecordingEntry(recordingEntry));
}
Expand Down Expand Up @@ -1765,6 +1770,11 @@ PVR_ERROR WaipuData::GetRecordings(bool deleted, kodi::addon::PVRRecordingsResul
if (status != "FINISHED" && status != "RECORDING")
continue;

if (recordingEntry.HasMember("locked") && recordingEntry["locked"].GetBool())
{
kodi::Log(ADDON_LOG_DEBUG, "[%s] Skip locked recording", __FUNCTION__);
continue;
}
recordings_count++;
results.Add(ParseRecordingEntry(recordingEntry));
}
Expand Down

0 comments on commit 3b94b3c

Please sign in to comment.