Add public constructor for Authority

This commit is contained in:
Vladimir Babin 2021-03-29 23:41:09 +05:00
parent 7caede2533
commit 22e300a8f1
1 changed files with 6 additions and 0 deletions

View File

@ -20,6 +20,12 @@ public struct Authority: VIZCodable, Equatable {
public var accountAuths: [Auth<String>]
/// Key auths.
public var keyAuths: [Auth<PublicKey>]
public init(weightThreshold: UInt32 = 1, accountAuths: [Auth<String>] = [], keyAuths: [Auth<PublicKey>]) {
self.weightThreshold = weightThreshold
self.accountAuths = accountAuths
self.keyAuths = keyAuths
}
}
extension Authority.Auth {