mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
Merge null/pattern checks into complex pattern.
This commit is contained in:
@@ -485,7 +485,7 @@ public static class MMC
|
||||
}
|
||||
|
||||
foreach(FullTOC.TrackDataDescriptor track in
|
||||
decodedToc.Value.TrackDescriptors.Where(t => t.POINT > 0 && t.POINT <= 0x99))
|
||||
decodedToc.Value.TrackDescriptors.Where(t => t.POINT is > 0 and <= 0x99))
|
||||
{
|
||||
if(track.TNO == 1 &&
|
||||
((TocControl)(track.CONTROL & 0x0D) == TocControl.DataTrack ||
|
||||
@@ -553,8 +553,7 @@ public static class MMC
|
||||
}
|
||||
|
||||
if(mediaType is MediaType.CD or MediaType.CDROM && hasDataTrack)
|
||||
foreach(uint startAddress in decodedToc.Value.TrackDescriptors.
|
||||
Where(t => t.POINT > 0 && t.POINT <= 0x99 &&
|
||||
foreach(uint startAddress in decodedToc.Value.TrackDescriptors.Where(t => t.POINT is > 0 and <= 0x99 &&
|
||||
((TocControl)(t.CONTROL & 0x0D) ==
|
||||
TocControl.DataTrack ||
|
||||
(TocControl)(t.CONTROL & 0x0D) ==
|
||||
@@ -2327,8 +2326,7 @@ public static class MMC
|
||||
}
|
||||
}
|
||||
|
||||
if(blurayDi != null &&
|
||||
blurayDi?.Units?.Length > 0 &&
|
||||
if(blurayDi is { Units.Length: > 0 } &&
|
||||
blurayDi?.Units[0].DiscTypeIdentifier != null)
|
||||
{
|
||||
string blurayType = StringHandlers.CToString(blurayDi?.Units[0].DiscTypeIdentifier);
|
||||
|
||||
Reference in New Issue
Block a user