Skip to content

Commit

Permalink
proper error
Browse files Browse the repository at this point in the history
  • Loading branch information
GhenadieVP committed Dec 23, 2024
1 parent e4e5f87 commit d9f75da
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 15 deletions.
27 changes: 18 additions & 9 deletions RadixWallet.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
objectVersion = 60;
objectVersion = 56;
objects = {

/* Begin PBXBuildFile section */
Expand Down Expand Up @@ -828,6 +828,7 @@
83377A052B9DDB5C00D8AA36 /* NPSSurveyClient+Live.swift in Sources */ = {isa = PBXBuildFile; fileRef = 83377A042B9DDB5C00D8AA36 /* NPSSurveyClient+Live.swift */; };
8338B9E52AFAB20700D1D8EA /* TransactionFee.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8338B9E42AFAB20700D1D8EA /* TransactionFee.swift */; };
834B651F2B972E5100B7E1E8 /* NPSSurvey.swift in Sources */ = {isa = PBXBuildFile; fileRef = 834B651E2B972E5100B7E1E8 /* NPSSurvey.swift */; };
835DFF932D19855A00229DB0 /* Sargon in Frameworks */ = {isa = PBXBuildFile; productRef = 835DFF922D19855A00229DB0 /* Sargon */; };
835F196D2B3581C300E0B71D /* UnknownDappComponents+View.swift in Sources */ = {isa = PBXBuildFile; fileRef = 835F196C2B3581C300E0B71D /* UnknownDappComponents+View.swift */; };
8370FC5C2B99C780007AD882 /* NPSSurveyClient+Interface.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8370FC5B2B99C780007AD882 /* NPSSurveyClient+Interface.swift */; };
8381C8B02BBD2CD400A470B4 /* TokenPriceCientTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8381C8AF2BBD2CD400A470B4 /* TokenPriceCientTests.swift */; };
Expand Down Expand Up @@ -2587,6 +2588,7 @@
5B1C4FD52BBB0B0C00B9436F /* AppsFlyerLib-Strict in Frameworks */,
48FFFB032ADC6F8100B2B213 /* Builders in Frameworks */,
48FFFAB72ADC207B00B2B213 /* NavigationTransitions in Frameworks */,
835DFF932D19855A00229DB0 /* Sargon in Frameworks */,
5B634A942C91D2A0004B2FBC /* ScreenshotPreventing in Frameworks */,
48FFFA992ADC1EEC00B2B213 /* AsyncExtensions in Frameworks */,
83B783562C1764AE00AA7930 /* Sargon in Frameworks */,
Expand Down Expand Up @@ -7110,6 +7112,7 @@
5B447E0A2CAAFC2D0063AE39 /* Sargon */,
5B4E1D1E2CB7FE8E002FAC2E /* Sargon */,
83D3F3C22D15C9CA00CA976D /* Sargon */,
835DFF922D19855A00229DB0 /* Sargon */,
);
productName = RadixWallet;
productReference = 48CFBC4F2ADC106300E77A5C /* Radix Wallet Dev.app */;
Expand Down Expand Up @@ -7180,7 +7183,7 @@
8318BB172BC8403800057BCB /* XCRemoteSwiftPackageReference "swift-custom-dump" */,
E6A0B0492BF23C7000617DAC /* XCRemoteSwiftPackageReference "swift-identified-collections" */,
5B634A922C91D2A0004B2FBC /* XCRemoteSwiftPackageReference "ScreenshotPreventing-iOS" */,
83D3F3C12D15C9CA00CA976D /* XCLocalSwiftPackageReference "../sargon" */,
835DFF912D19855A00229DB0 /* XCRemoteSwiftPackageReference "sargon" */,
);
productRefGroup = 48CFBC502ADC106300E77A5C /* Products */;
projectDirPath = "";
Expand Down Expand Up @@ -9020,13 +9023,6 @@
};
/* End XCConfigurationList section */

/* Begin XCLocalSwiftPackageReference section */
83D3F3C12D15C9CA00CA976D /* XCLocalSwiftPackageReference "../sargon" */ = {
isa = XCLocalSwiftPackageReference;
relativePath = ../sargon;
};
/* End XCLocalSwiftPackageReference section */

/* Begin XCRemoteSwiftPackageReference section */
48FFFA972ADC1EEC00B2B213 /* XCRemoteSwiftPackageReference "AsyncExtensions" */ = {
isa = XCRemoteSwiftPackageReference;
Expand Down Expand Up @@ -9276,6 +9272,14 @@
version = 1.3.0;
};
};
835DFF912D19855A00229DB0 /* XCRemoteSwiftPackageReference "sargon" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/radixdlt/sargon";
requirement = {
kind = exactVersion;
version = 1.1.96;
};
};
A415574E2B757C5E0040AD4E /* XCRemoteSwiftPackageReference "swift-composable-architecture" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/pointfreeco/swift-composable-architecture";
Expand Down Expand Up @@ -9508,6 +9512,11 @@
isa = XCSwiftPackageProductDependency;
productName = Sargon;
};
835DFF922D19855A00229DB0 /* Sargon */ = {
isa = XCSwiftPackageProductDependency;
package = 835DFF912D19855A00229DB0 /* XCRemoteSwiftPackageReference "sargon" */;
productName = Sargon;
};
83B783552C1764AE00AA7930 /* Sargon */ = {
isa = XCSwiftPackageProductDependency;
productName = Sargon;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"originHash" : "57e73c1e35205ff62c58957bd54353493e825efa806ed93e14b9ed1dc1fca51d",
"originHash" : "4eb650ade57061cd1cf989ce8f615547774e9303f591ff57a76f3f2c04cdbd07",
"pins" : [
{
"identity" : "anycodable",
Expand Down Expand Up @@ -109,6 +109,15 @@
"version" : "11.6.4"
}
},
{
"identity" : "sargon",
"kind" : "remoteSourceControl",
"location" : "https://github.com/radixdlt/sargon",
"state" : {
"revision" : "2f610dafec01e66542d6902f02aeffda83dbc7cd",
"version" : "1.1.96"
}
},
{
"identity" : "screenshotpreventing-ios",
"kind" : "remoteSourceControl",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,12 +117,12 @@ struct PreAuthorizationReview: Sendable, FeatureReducer {
switch internalAction {
case let .previewLoaded(.failure(error)):
loggerGlobal.error("PreAuthroization preview failed, error: \(error)")
errorQueue.schedule(error)
guard let failure = error as? TransactionFailure else {
assertionFailure("Failed with unexpected error \(error)")
return .none
errorQueue.schedule(TransactionReviewFailure(underylying: error))
if let txFailure = error as? TransactionFailure {
return .send(.delegate(.failed(txFailure)))
} else {
return .send(.delegate(.failed(TransactionFailure.failedToPrepareTXReview(.abortedTXReview(error)))))
}
return .send(.delegate(.failed(failure)))

case let .previewLoaded(.success(preview)):
state.preview = preview
Expand Down

0 comments on commit d9f75da

Please sign in to comment.