Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: getbouncer/cardscan-ios
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.0.4047
Choose a base ref
...
head repository: getbouncer/cardscan-ios
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 1.0.4048
Choose a head ref
  • 2 commits
  • 6 files changed
  • 1 contributor

Commits on May 4, 2019

  1. Verified

    This commit was signed with the committer’s verified signature.
    thaJeztah Sebastiaan van Stijn
    Copy the full SHA
    4ad49df View commit details
  2. Merge pull request #16 from getbouncer/unredacted_card_image

    Give the option of getting the cardImage back in the CreditCard object
    kingst authored May 4, 2019
    Copy the full SHA
    8dc73f8 View commit details
2 changes: 1 addition & 1 deletion CardScan.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'CardScan'
s.version = '1.0.4047'
s.version = '1.0.4048'
s.summary = 'Scan credit cards'
s.description = <<-DESC
CardScan is a library for scanning credit cards.
5 changes: 5 additions & 0 deletions CardScan/Classes/ScanViewController.swift
Original file line number Diff line number Diff line change
@@ -36,6 +36,7 @@ import Vision
@objc public var expiryMonth: String?
@objc public var expiryYear: String?
@objc public var name: String?
@objc public var image: UIImage?

public init(number: String) {
self.number = number
@@ -62,6 +63,7 @@ import Vision
public var allowSkip = false
public var scanQrCode = false
public var errorCorrectionDuration = 1.5
public var includeCardImage = false

static public let machineLearningQueue = DispatchQueue(label: "CardScanMlQueue")

@@ -427,6 +429,9 @@ import Vision
let card = CreditCard(number: number)
card.expiryMonth = expiry.map { String($0.month) }
card.expiryYear = expiry.map { String($0.year) }
if self.includeCardImage {
card.image = UIImage(cgImage: rawImage)
}
self.scanDelegate?.userDidScanCard(self, creditCard: card)
}
}
Loading