1 | // Copyright 2017-2022 @polkadot/util-crypto authors & contributors
|
2 | // SPDX-License-Identifier: Apache-2.0
|
3 | import { encodeAddress } from "./encode.js";
|
4 | import { createKeyMulti } from "./keyMulti.js";
|
5 | /**
|
6 | * @name encodeMultiAddress
|
7 | * @summary Creates a multisig address.
|
8 | * @description
|
9 | * Creates a Substrate multisig address based on the input address and the required threshold.
|
10 | */
|
11 |
|
12 | export function encodeMultiAddress(who, threshold, ss58Format) {
|
13 | return encodeAddress(createKeyMulti(who, threshold), ss58Format);
|
14 | } |
\ | No newline at end of file |