Skip to content

Commit

Permalink
fixup! fix(addAssetToVault): support issuerName separate from keyword
Browse files Browse the repository at this point in the history
  • Loading branch information
dckc committed Oct 3, 2023
1 parent 7b29446 commit 65c0d76
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions packages/inter-protocol/src/proposals/addAssetToVault.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ export * from './startPSM.js';
* @property {string} [issuerBoardId]
* @property {string} [denom]
* @property {number} [decimalPlaces]
* @property {string} [proposedName]
* @property {string} keyword
* @property {string} [issuerName]
* @property {string} [oracleBrand]
* @property {string} keyword - used in regstering with reserve, vaultFactory
* @property {string} [issuerName] - used in agoricNames for compatibility:
* defaults to `keyword` if not provided
* @property {string} [proposedName] - defaults to `issuerName` if not provided
* @property {string} [oracleBrand] - defaults to `issuerName` if not provided
* @property {number} [initialPrice]
*/

Expand Down Expand Up @@ -78,9 +79,9 @@ export const publishInterchainAssetFromBank = async (
// Incompatible with issuerBoardId.
assert.equal(interchainAssetOptions.issuerBoardId, undefined);
assert.typeof(denom, 'string');
assert.typeof(decimalPlaces, 'number');
assert.typeof(issuerName, 'string');
assert.typeof(proposedName, 'string');
assert.typeof(decimalPlaces, 'number');

const terms = {
keyword: issuerName, // "keyword" is a misnomer in mintHolder terms
Expand Down Expand Up @@ -128,8 +129,8 @@ export const registerScaledPriceAuthority = async (
{ options: { interchainAssetOptions } },
) => {
const {
keyword: kwd,
issuerName = kwd,
keyword,
issuerName = keyword,
oracleBrand = issuerName,
initialPrice: initialPriceRaw,
} = interchainAssetOptions;
Expand Down

0 comments on commit 65c0d76

Please sign in to comment.