Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

Commit

Permalink
Merge pull request #35 from kinecosystem/issue-29
Browse files Browse the repository at this point in the history
Bugfix: issue 29
  • Loading branch information
samdowd authored Oct 7, 2021
2 parents d9981e9 + 4017cf5 commit bb7467a
Show file tree
Hide file tree
Showing 14 changed files with 40 additions and 21 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,7 @@ fastlane/report.xml
fastlane/Preview.html
fastlane/screenshots/**/*.png
fastlane/test_output

# Gem bundle
/.bundle/
/vendor/
2 changes: 1 addition & 1 deletion KinBase.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#
Pod::Spec.new do |s|
s.name = 'KinBase'
s.version = '2.1.0'
s.version = '2.1.1'
s.summary = 'Kin SDK for iOS'

s.description = <<-DESC
Expand Down
4 changes: 2 additions & 2 deletions KinBase/KinBase.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1799,7 +1799,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
OTHER_LDFLAGS = (
"$(inherited)",
"-l\"c++\"",
Expand Down Expand Up @@ -1841,7 +1841,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
ONLY_ACTIVE_ARCH = YES;
OTHER_LDFLAGS = (
"$(inherited)",
Expand Down
11 changes: 9 additions & 2 deletions KinBase/KinBase/Src/Model/KinTransaction.swift
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ public class KinTransaction: Equatable, KinTransactionType {
public var memo: KinMemo

public var paymentOperations: [KinPaymentOperation]

public enum Errors: Error {
case unknown
}

init(envelopeXdrBytes: [Byte], record: Record, network: KinNetwork, invoiceList: InvoiceList? = nil, historyItem: APBTransactionV4HistoryItem? = nil) throws {
self.envelopeXdrBytes = envelopeXdrBytes
Expand All @@ -102,9 +106,12 @@ public class KinTransaction: Equatable, KinTransactionType {
self.memo = solanaTransaction.memo
self.paymentOperations = solanaTransaction.paymentOperations
} else {
let payments = historyItem!.paymentsArray as NSArray as! [APBTransactionV4HistoryItem_Payment]
guard let historyItem = historyItem else {
throw Errors.unknown
}
let payments = historyItem.paymentsArray as NSArray as! [APBTransactionV4HistoryItem_Payment]
let payment = payments.first!
self.transactionHash = KinTransactionHash(historyItem!.transactionId.value)
self.transactionHash = KinTransactionHash(historyItem.transactionId.value)
self.sourceAccount = payment.source.publicKey
self.memo = KinMemo.none
self.paymentOperations = payments.compactMap {
Expand Down
2 changes: 1 addition & 1 deletion KinBase/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ The KinBase module is the foundation upon which the rest of the SDK stands.
## Installation
Add the following to your Podfile.
```
pod 'KinBase', '~> 2.1.0'
pod 'KinBase', '~> 2.1.1'
```

## Overview
Expand Down
2 changes: 1 addition & 1 deletion KinDesign.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
Pod::Spec.new do |s|
s.name = 'KinDesign'
s.version = '2.1.0'
s.version = '2.1.1'
s.summary = 'Kin Design Library for iOS'

s.description = <<-DESC
Expand Down
4 changes: 2 additions & 2 deletions KinDesign/KinDesign.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
PRODUCT_BUNDLE_IDENTIFIER = org.kin..KinDesign;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
Expand Down Expand Up @@ -458,7 +458,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
PRODUCT_BUNDLE_IDENTIFIER = org.kin..KinDesign;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
Expand Down
2 changes: 1 addition & 1 deletion KinDesign/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ All of these components can be tested out and browsed in the [sample app](../Kin
## Installation
Add the following to your project's Podfile.
```
pod 'KinDesign', '~> 2.1.0'
pod 'KinDesign', '~> 2.1.1'
```

### Primary Button
Expand Down
4 changes: 2 additions & 2 deletions KinSampleApp/KinSampleApp.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
PRODUCT_BUNDLE_IDENTIFIER = org.kin..KinSampleApp;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
Expand All @@ -602,7 +602,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
PRODUCT_BUNDLE_IDENTIFIER = org.kin..KinSampleApp;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
Expand Down
6 changes: 3 additions & 3 deletions KinUX.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
Pod::Spec.new do |s|
s.name = 'KinUX'
s.version = '2.1.0'
s.version = '2.1.1'
s.summary = 'UX Library for Kin SDK iOS'

s.description = <<-DESC
Expand All @@ -20,8 +20,8 @@ Pod::Spec.new do |s|

s.source_files = 'KinUX/KinUX/Src/**/*'

s.dependency 'KinBase', '~> 2.1.0'
s.dependency 'KinDesign', '~> 2.1.0'
s.dependency 'KinBase', '~> 2.1.1'
s.dependency 'KinDesign', '~> 2.1.1'

# Dependencies needed for KinGrpcApi
s.dependency 'gRPC-ProtoRPC'
Expand Down
4 changes: 2 additions & 2 deletions KinUX/KinUX.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
PRODUCT_BUNDLE_IDENTIFIER = org.kin..KinUX;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
Expand Down Expand Up @@ -619,7 +619,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 2.1.0;
MARKETING_VERSION = 2.1.1;
PRODUCT_BUNDLE_IDENTIFIER = org.kin..KinUX;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
Expand Down
2 changes: 1 addition & 1 deletion KinUX/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ The KinUX module provides an easy to use out of the box spend flow UI that is pr
Add the following to your project's Podfile.
This will also transitively pull in KinBase and KinDesign into your project as well.
```
pod 'KinUX', '~> 2.1.0'
pod 'KinUX', '~> 2.1.1'
```

## Overview
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ In your Podfile

```
// If you just want to access the blockchain & no UI
pod 'KinBase', '~> 2.1.0'
pod 'KinBase', '~> 2.1.1'
// Add spend to use the modal spend flow to allow users to buy things with Kin
pod 'KinUX', '~> 2.1.0'
pod 'KinUX', '~> 2.1.1'
// Add design for direct access to UI views you can use in your own app
pod 'KinDesign', '~> 2.1.0'
pod 'KinDesign', '~> 2.1.1'
```

## Sample App
Expand Down
8 changes: 8 additions & 0 deletions kin-ios.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>PreviewsEnabled</key>
<false/>
</dict>
</plist>

0 comments on commit bb7467a

Please sign in to comment.