Skip to content

Commit

Permalink
Merge pull request #151 from xmanu/fix-strong-ref-cycle
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanfallet committed Sep 11, 2024
2 parents 34da57f + b1b57e6 commit 9fa582f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Sources/CodeScanner/ScannerViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,8 @@ extension CodeScannerView.ScannerViewController: AVCaptureMetadataOutputObjectsD
return
}

handler = { [self] image in
handler = { [weak self] image in
guard let self else { return }
let result = ScanResult(string: stringValue, type: readableObject.type, image: image, corners: readableObject.corners)

switch parentView.scanMode {
Expand Down

0 comments on commit 9fa582f

Please sign in to comment.