Skip to content

Commit

Permalink
Both - Hot fix, History api parsing key update (time & timestamp)
Browse files Browse the repository at this point in the history
  • Loading branch information
wannabit-yongjoo committed Sep 3, 2020
1 parent f9af2c3 commit b5f6402
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package wannabit.io.cosmostaion.base;

public class BaseConstant {
public final static boolean IS_SHOWLOG = true;
public final static boolean IS_SHOWLOG = false;
public final static boolean IS_TEST = false;
public final static boolean IS_FEE_FREE = false;
public final static boolean SUPPORT_MOONPAY = true;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public class Data {
@SerializedName("memo")
public String memo;

@SerializedName("time")
@SerializedName(value="time", alternate={"timestamp"})
public String time;

@SerializedName("logs")
Expand Down
9 changes: 8 additions & 1 deletion Cosmos-IOS/Cosmostation/Cosmostation/Model/ApiHistory.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,14 @@ public class ApiHistory {
self.height = dictionary["height"] as? Int64 ?? -1
self.tx_hash = dictionary["tx_hash"] as? String ?? ""
self.memo = dictionary["memo"] as? String ?? ""
self.time = dictionary["time"] as? String ?? ""
self.time = dictionary["timestamp"] as? String ?? ""

if let rawTime = dictionary["time"] as? String {
self.time = rawTime
}
if let rawTime = dictionary["timestamp"] as? String {
self.time = rawTime
}

if let feedata = dictionary["fee"] as? [String : Any] {
self.fee = Fee.init(feedata)
Expand Down

0 comments on commit b5f6402

Please sign in to comment.