From 0abc01117f6320847b3997694cac22ace11e754a Mon Sep 17 00:00:00 2001 From: Michael Bisgaard Olesen Date: Mon, 5 Feb 2024 15:26:40 +0100 Subject: [PATCH] Revert formatting changes --- Sources/ConcordiumSwiftSdk/Model/Chain.swift | 6 ++-- .../GrpcCli/Sources/GrpcCli/GrpcCli.swift | 36 +++++++++---------- 2 files changed, 21 insertions(+), 21 deletions(-) diff --git a/Sources/ConcordiumSwiftSdk/Model/Chain.swift b/Sources/ConcordiumSwiftSdk/Model/Chain.swift index 381a4c3..1d11d3b 100644 --- a/Sources/ConcordiumSwiftSdk/Model/Chain.swift +++ b/Sources/ConcordiumSwiftSdk/Model/Chain.swift @@ -7,9 +7,9 @@ public struct CryptographicParameters { static func fromGrpcType(_ grpc: Concordium_V2_CryptographicParameters) -> CryptographicParameters { CryptographicParameters( - onChainCommitmentKey: grpc.onChainCommitmentKey.hexadecimalString(), - bulletproofGenerators: grpc.bulletproofGenerators.hexadecimalString(), - genesisString: grpc.genesisString + onChainCommitmentKey: grpc.onChainCommitmentKey.hexadecimalString(), + bulletproofGenerators: grpc.bulletproofGenerators.hexadecimalString(), + genesisString: grpc.genesisString ) } } diff --git a/examples/GrpcCli/Sources/GrpcCli/GrpcCli.swift b/examples/GrpcCli/Sources/GrpcCli/GrpcCli.swift index 87247ce..30dfc52 100644 --- a/examples/GrpcCli/Sources/GrpcCli/GrpcCli.swift +++ b/examples/GrpcCli/Sources/GrpcCli/GrpcCli.swift @@ -52,14 +52,14 @@ struct GrpcCli: AsyncParsableCommand { var options: GrpcOptions static var configuration = CommandConfiguration( - abstract: "A CLI for demonstrating and testing use of the gRPC client of the SDK.", - version: "1.0.0", - subcommands: [CryptographicParameters.self, Account.self] + abstract: "A CLI for demonstrating and testing use of the gRPC client of the SDK.", + version: "1.0.0", + subcommands: [CryptographicParameters.self, Account.self] ) struct CryptographicParameters: AsyncParsableCommand { static var configuration = CommandConfiguration( - abstract: "Display the cryptographic parameters of the chain." + abstract: "Display the cryptographic parameters of the chain." ) @OptionGroup @@ -71,7 +71,7 @@ struct GrpcCli: AsyncParsableCommand { func run() async throws { let res = try await withClient(target: root.options.target) { try await $0.getCryptographicParameters( - at: block.block + at: block.block ) } print(res) @@ -80,8 +80,8 @@ struct GrpcCli: AsyncParsableCommand { struct Account: AsyncParsableCommand { static var configuration = CommandConfiguration( - abstract: "Subcommands related to a particular account.", - subcommands: [NextSequenceNumber.self, Info.self] + abstract: "Subcommands related to a particular account.", + subcommands: [NextSequenceNumber.self, Info.self] ) @OptionGroup @@ -89,7 +89,7 @@ struct GrpcCli: AsyncParsableCommand { struct NextSequenceNumber: AsyncParsableCommand { static var configuration = CommandConfiguration( - abstract: "Display the next sequence number of the provided account." + abstract: "Display the next sequence number of the provided account." ) @OptionGroup @@ -101,7 +101,7 @@ struct GrpcCli: AsyncParsableCommand { func run() async throws { let res = try await withClient(target: root.options.target) { try await $0.getNextAccountSequenceNumber( - of: account.account.address + of: account.account.address ) } print(res) @@ -110,7 +110,7 @@ struct GrpcCli: AsyncParsableCommand { struct Info: AsyncParsableCommand { static var configuration = CommandConfiguration( - abstract: "Display info of the provided account." + abstract: "Display info of the provided account." ) @OptionGroup @@ -125,8 +125,8 @@ struct GrpcCli: AsyncParsableCommand { func run() async throws { let res = try await withClient(target: root.options.target) { try await $0.getAccountInfo( - of: account.account.identifier, - at: block.block + of: account.account.identifier, + at: block.block ) } print(res) @@ -135,7 +135,7 @@ struct GrpcCli: AsyncParsableCommand { struct Transer: AsyncParsableCommand { static var configuration = CommandConfiguration( - abstract: "Transfer amount between accounts." + abstract: "Transfer amount between accounts." ) @OptionGroup @@ -153,10 +153,10 @@ struct GrpcCli: AsyncParsableCommand { func run() async throws { let res = try await withClient(target: root.options.target) { let sequenceNumber = try await $0.getNextAccountSequenceNumber( - of: sender.account.address + of: sender.account.address ) try await $0.sendSimpleTransfer(from: sender.account.address, to: receiver.account.address, microCcdAmount: amount, sequenceNumber: SequenceNumber, privateKey: Curve25519.Signing.PrivateKey.getNextAccountSequenceNumber( - of: sender.account.address + of: sender.account.address )) } print(res) @@ -171,9 +171,9 @@ func withClient(target: ConnectionTarget, _ cmd: (ConcordiumNodeClient) async try! group.syncShutdownGracefully() } let channel = try GRPCChannelPool.with( - target: target, - transportSecurity: .plaintext, - eventLoopGroup: group + target: target, + transportSecurity: .plaintext, + eventLoopGroup: group ) defer { try! channel.close().wait()