From 29b107f93763420c5bc0cbde38c68e40e705ff38 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Thu, 1 Jun 2017 18:46:07 +0200 Subject: fix terminology, better types --- src/webex/renderHtml.tsx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/webex/renderHtml.tsx') diff --git a/src/webex/renderHtml.tsx b/src/webex/renderHtml.tsx index 70cd61d62..4dd7baded 100644 --- a/src/webex/renderHtml.tsx +++ b/src/webex/renderHtml.tsx @@ -27,7 +27,7 @@ import { amountToPretty } from "../helpers"; import * as i18n from "../i18n"; import { - Contract, + ContractTerms, } from "../types"; import * as React from "react"; @@ -35,14 +35,14 @@ import * as React from "react"; /** * Render contract terms for the end user to view. */ -export function renderContract(contract: Contract): JSX.Element { +export function renderContractTerms(contractTerms: ContractTerms): JSX.Element { let merchantName; - if (contract.merchant && contract.merchant.name) { - merchantName = {contract.merchant.name}; + if (contractTerms.merchant && contractTerms.merchant.name) { + merchantName = {contractTerms.merchant.name}; } else { - merchantName = (pub: {contract.merchant_pub}); + merchantName = (pub: {contractTerms.merchant_pub}); } - const amount = {amountToPretty(contract.amount)}; + const amount = {amountToPretty(contractTerms.amount)}; return (
@@ -53,7 +53,7 @@ export function renderContract(contract: Contract): JSX.Element {

{i18n.str`You are about to purchase:`}

-- cgit v1.2.3