Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
romanmazeev committed Feb 26, 2025
1 parent b1935b6 commit c682333
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 27 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"originHash" : "ac7e7cc0e53ac69ab0496d2fa9ac62eb79de65fb639ee854c714910eac1d991f",
"originHash" : "f1429daeefed15105d9ada5a1bf13797e9888c1e7a6ec51a743f3c0c2c757348",
"pins" : [
{
"identity" : "combine-schedulers",
Expand All @@ -15,8 +15,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/romanmazeev/MRZParser.git",
"state" : {
"revision" : "9ecd6c63d155e2441465627fc256c9e3ce035c0b",
"version" : "1.3.0"
"revision" : "0b66b55429d2a1501bdfa027fab7ccced103a12d",
"version" : "1.3.1"
}
},
{
Expand Down Expand Up @@ -51,8 +51,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-dependencies",
"state" : {
"revision" : "52b5e1a09dc016e64ce253e19ab3124b7fae9ac9",
"version" : "1.7.0"
"revision" : "121a428c505c01c4ce02d5ada1c8fc3da93afce9",
"version" : "1.8.0"
}
},
{
Expand Down
9 changes: 3 additions & 6 deletions Example/MRZScannerExample/ContentView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,8 @@ struct ContentView: View {
private func createAlertMessage(result: Result<ParserResult, Error>) -> String {
switch result {
case .success(let mrzResult):
var birthdateString: String?
var expiryDateString: String?

birthdateString = dateFormatter.string(from: mrzResult.birthdate)
expiryDateString = dateFormatter.string(from: mrzResult.expiryDate)
let birthdateString = dateFormatter.string(from: mrzResult.birthdate)
let expiryDateString = mrzResult.expiryDate.map { dateFormatter.string(from: $0) }

return """
Document type: \(mrzResult.documentType)
Expand All @@ -119,7 +116,7 @@ struct ContentView: View {
Given names: \(mrzResult.names.givenNames ?? "-")
Document number: \(mrzResult.documentNumber)
nationalityCountryCode: \(mrzResult.nationalityCountryCode)
birthdate: \(birthdateString ?? "-")
birthdate: \(birthdateString)
sex: \(mrzResult.sex)
expiryDate: \(expiryDateString ?? "-")
personalNumber: \(mrzResult.optionalData ?? "-")
Expand Down
22 changes: 11 additions & 11 deletions Package.resolved
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"originHash" : "ac7e7cc0e53ac69ab0496d2fa9ac62eb79de65fb639ee854c714910eac1d991f",
"originHash" : "f1429daeefed15105d9ada5a1bf13797e9888c1e7a6ec51a743f3c0c2c757348",
"pins" : [
{
"identity" : "combine-schedulers",
Expand All @@ -15,8 +15,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/romanmazeev/MRZParser.git",
"state" : {
"revision" : "9ecd6c63d155e2441465627fc256c9e3ce035c0b",
"version" : "1.3.0"
"revision" : "0b66b55429d2a1501bdfa027fab7ccced103a12d",
"version" : "1.3.1"
}
},
{
Expand All @@ -33,8 +33,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-concurrency-extras",
"state" : {
"revision" : "bb5059bde9022d69ac516803f4f227d8ac967f71",
"version" : "1.1.0"
"revision" : "82a4ae7170d98d8538ec77238b7eb8e7199ef2e8",
"version" : "1.3.1"
}
},
{
Expand All @@ -51,26 +51,26 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-dependencies",
"state" : {
"revision" : "52b5e1a09dc016e64ce253e19ab3124b7fae9ac9",
"version" : "1.7.0"
"revision" : "121a428c505c01c4ce02d5ada1c8fc3da93afce9",
"version" : "1.8.0"
}
},
{
"identity" : "swift-syntax",
"kind" : "remoteSourceControl",
"location" : "https://github.com/swiftlang/swift-syntax",
"state" : {
"revision" : "303e5c5c36d6a558407d364878df131c3546fad8",
"version" : "510.0.2"
"revision" : "0687f71944021d616d34d922343dcef086855920",
"version" : "600.0.1"
}
},
{
"identity" : "xctest-dynamic-overlay",
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/xctest-dynamic-overlay",
"state" : {
"revision" : "b444594f79844b0d6d76d70fbfb3f7f71728f938",
"version" : "1.5.1"
"revision" : "39de59b2d47f7ef3ca88a039dff3084688fe27f4",
"version" : "1.5.2"
}
}
],
Expand Down
4 changes: 2 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ let package = Package(
),
],
dependencies: [
.package(url: "https://github.com/romanmazeev/MRZParser.git", from: "1.3.0"),
.package(url: "https://github.com/pointfreeco/swift-dependencies", from: "1.7.0"),
.package(url: "https://github.com/romanmazeev/MRZParser.git", from: "1.3.1"),
.package(url: "https://github.com/pointfreeco/swift-dependencies", from: "1.8.0"),
.package(url: "https://github.com/pointfreeco/swift-custom-dump.git", from: "1.3.3")
],
targets: [
Expand Down
2 changes: 1 addition & 1 deletion Tests/MRZScannerTests/Public/ScanningResultTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ private extension ParserResult {
mrzKey: "",
format: .td2(isVisaDocument: false),
documentType: .id,
documentTypeAdditional: "r",
documentTypeAdditional: .national,
countryCode: "thirdTest",
names: .init(surnames: "thirdTest", givenNames: "thirdTest"),
documentNumber: "thirdTest",
Expand Down
4 changes: 2 additions & 2 deletions Tests/MRZScannerTests/SharedMocks.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ extension ParserResult {
mrzKey: "",
format: .td3(isVisaDocument: false),
documentType: .passport,
documentTypeAdditional: "A",
documentTypeAdditional: nil,
countryCode: "test",
names: .init(surnames: "test", givenNames: "test"),
documentNumber: "test",
Expand All @@ -32,7 +32,7 @@ extension ParserResult {
mrzKey: "",
format: .td1,
documentType: .passport,
documentTypeAdditional: "r",
documentTypeAdditional: .diplomatic,
countryCode: "secondTest",
names: .init(surnames: "secondTest", givenNames: "secondTest"),
documentNumber: "secondTest",
Expand Down

0 comments on commit c682333

Please sign in to comment.