chore: Rename CodeScanner to CodeScannerOptions in native (#2010)

* chore: Rename `CodeScanner` to `CodeScannerOptions` on native

* chore: Rename `CodeScanner` on iOS

* fix: Unwrap `options`

* Format
This commit is contained in:
Marc Rousavy
2023-10-16 16:56:39 +02:00
committed by GitHub
parent e8ae11e30b
commit 5e20f9c8fa
10 changed files with 31 additions and 23 deletions

View File

@@ -179,8 +179,8 @@ public final class CameraView: UIView, CameraSessionDelegate {
// Code Scanner
if let codeScannerOptions {
let codeScanner = try CodeScanner(fromJsValue: codeScannerOptions)
config.codeScanner = .enabled(config: codeScanner)
let options = try CodeScannerOptions(fromJsValue: codeScannerOptions)
config.codeScanner = .enabled(config: CameraConfiguration.CodeScanner(options: options))
} else {
config.codeScanner = .disabled
}