More pattern matching.

This commit is contained in:
2022-11-14 01:49:09 +00:00
parent e6db6032f3
commit a02220902c
8 changed files with 11 additions and 22 deletions

View File

@@ -55,8 +55,7 @@ public static class Session
{
public static CDSessionInfo? Decode(byte[] CDSessionInfoResponse)
{
if(CDSessionInfoResponse == null ||
CDSessionInfoResponse.Length <= 4)
if(CDSessionInfoResponse is not { Length: > 4 })
return null;
var decoded = new CDSessionInfo