<!--
{
  "availability" : [
    "iOS: 16.4.0 -",
    "iPadOS: 16.4.0 -",
    "macCatalyst: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "ProximityReader",
  "identifier" : "/documentation/ProximityReader/PaymentCardReader/Options-swift.struct/includeErrorInReadResult",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "ProximityReader"
    ],
    "preciseIdentifier" : "s:15ProximityReader011PaymentCardB0C7OptionsV24includeErrorInReadResultSbvp"
  },
  "title" : "includeErrorInReadResult"
}
-->

# includeErrorInReadResult

A Boolean value that indicates whether the framework returns a result instead of throwing an error when some data is retrievable.

```
var includeErrorInReadResult: Bool
```

## Discussion

The default value  is `false`.

After the framework reads a payment card, when there’s an error, the framework discards  [`PaymentCardReadResult`](/documentation/ProximityReader/PaymentCardReadResult) and throws an error.

When you set this option to `true`, if an error arises, the framework doesn’t throw an error, instead the [`PaymentCardReadResult`](/documentation/ProximityReader/PaymentCardReadResult)
includes both the [`outcome`](/documentation/ProximityReader/PaymentCardReadResult/outcome) and the data that the framework can retrieve.
You’re responsible for checking the outcome in addition to catching errors the framework throws.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)