If you attempt calling SmartCardReader reader = await CardReader.FindAsync() and no card reader is connected, you will get "System.NullReferenceException: Object reference not set to an instance of an object.", because it attempts to await null. It should either return Task.FromResult(null), or be rewritten so it's actually async.
The workaround I had to use is SmartCardReader reader = CardReader.FindAsync()?.Result;
If you attempt calling(null), or be rewritten so it's actually async.
SmartCardReader reader = await CardReader.FindAsync()
and no card reader is connected, you will get "System.NullReferenceException: Object reference not set to an instance of an object.", because it attempts to await null. It should either return Task.FromResultThe workaround I had to use is
SmartCardReader reader = CardReader.FindAsync()?.Result;