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:
@@ -74,10 +74,10 @@ public sealed class ZZZNoFilter : IFilter
|
||||
public bool HasResourceFork => false;
|
||||
|
||||
/// <inheritdoc />
|
||||
public bool Identify(byte[] buffer) => buffer != null && buffer.Length > 0;
|
||||
public bool Identify(byte[] buffer) => buffer is { Length: > 0 };
|
||||
|
||||
/// <inheritdoc />
|
||||
public bool Identify(Stream stream) => stream != null && stream.Length > 0;
|
||||
public bool Identify(Stream stream) => stream is { Length: > 0 };
|
||||
|
||||
/// <inheritdoc />
|
||||
public bool Identify(string path) => File.Exists(path);
|
||||
|
||||
Reference in New Issue
Block a user