Skip to content

Commit

Permalink
Prep for zero fraud (#235)
Browse files Browse the repository at this point in the history
* Tinkering with zero fraud

* Make sure that programmatic UI buttons animate
  • Loading branch information
kingst authored Dec 1, 2020
1 parent 9c8e421 commit 9722722
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CardScan/Classes/ScanViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ import UIKit
@objc public var expiryYear: String?
@objc public var name: String?
@objc public var image: UIImage?
@objc public var cvv: String?
@objc public var postalCode: String?

public init(number: String) {
self.number = number
Expand Down
8 changes: 4 additions & 4 deletions CardScan/Classes/SimpleScanViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,10 @@ open class SimpleScanViewController: ScanBaseViewController {

// our UI components
public var descriptionText = UILabel()
public var closeButton = UIButton()
public var torchButton = UIButton()
public var closeButton = UIButton(type: .system)
public var torchButton = UIButton(type: .system)
private var debugView: UIImageView?
public var enableCameraPermissionsButton = UIButton()
public var enableCameraPermissionsButton = UIButton(type: .system)
public var enableCameraPermissionsText = UILabel()

// Dynamic card details
Expand Down Expand Up @@ -358,7 +358,7 @@ open class SimpleScanViewController: ScanBaseViewController {
showScannedCardDetails(prediction: prediction)
}

override public func onCameraPermissionDenied(showedPrompt: Bool) {
override open func onCameraPermissionDenied(showedPrompt: Bool) {
descriptionText.isHidden = true
torchButton.isHidden = true

Expand Down

0 comments on commit 9722722

Please sign in to comment.