Skip to content

Commit 4c0643a

Browse files
Marcus ArnettMarcus Arnett
authored andcommitted
Implement lint for coin objects
1 parent 49fab86 commit 4c0643a

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

Sources/SuiKit/Types/Structs/Coin/CoinBalance.swift

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,12 @@ public struct CoinBalance: Equatable {
4343
/// Locked balance is the portion of the total balance that is restricted or not readily available for use.
4444
public let lockedBalance: LockedBalance?
4545

46-
public init(coinType: String, coinObjectCount: Int, totalBalance: String, lockedBalance: LockedBalance?) throws {
46+
public init(
47+
coinType: String,
48+
coinObjectCount: Int,
49+
totalBalance: String,
50+
lockedBalance: LockedBalance?
51+
) throws {
4752
self.coinType = try StructTag.fromStr(coinType)
4853
self.coinObjectCount = coinObjectCount
4954
self.totalBalance = totalBalance

Sources/SuiKit/Types/Structs/Coin/PaginatedCoins.swift

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,19 @@ public struct PaginatedCoins: Equatable {
3434
/// A string representing the object identifier (objectId) for the next cursor in the pagination.
3535
/// It is used to retrieve the next page of `CoinStruct` objects.
3636
public let nextCursor: objectId?
37-
37+
38+
/// The object corresponding to the information of the current coin page.
3839
public let pageInfo: PageInfo?
3940

4041
/// A boolean value indicating whether there is a next page available in the pagination.
4142
public let hasNextPage: Bool?
4243

43-
public init(data: [CoinStruct], nextCursor: objectId? = nil, pageInfo: PageInfo? = nil, hasNextPage: Bool? = nil) {
44+
public init(
45+
data: [CoinStruct],
46+
nextCursor: objectId? = nil,
47+
pageInfo: PageInfo? = nil,
48+
hasNextPage: Bool? = nil
49+
) {
4450
self.data = data
4551
self.nextCursor = nextCursor
4652
self.pageInfo = pageInfo

0 commit comments

Comments
 (0)