From e575692a49c06c6e47733d0f33c50c17681bbad3 Mon Sep 17 00:00:00 2001 From: Angelos Chalaris Date: Fri, 2 Aug 2024 16:10:08 +0300 Subject: [PATCH] Fix some typos in a snippet --- .../js/s/modeling-money-currency-exchange-rates.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/content/snippets/js/s/modeling-money-currency-exchange-rates.md b/content/snippets/js/s/modeling-money-currency-exchange-rates.md index 0d3fa653daf..39eabf521ce 100644 --- a/content/snippets/js/s/modeling-money-currency-exchange-rates.md +++ b/content/snippets/js/s/modeling-money-currency-exchange-rates.md @@ -272,7 +272,7 @@ class Bank { exchange(money, to) { if (!(money instanceof Money)) - throw new TypeError(`#{money} is not an instance of Money`); + throw new TypeError(`${money} is not an instance of Money`); const toCurrency = Currency.wrap(to); if (toCurrency === money.currency) return money; @@ -306,7 +306,7 @@ class Money { this.value = Number.parseFloat(value); this.currency = Currency.wrap(currency); if (!(bank instanceof Bank)) - throw new TypeError(`#{bank} is not an instance of Bank`); + throw new TypeError(`${bank} is not an instance of Bank`); this.bank = bank; } @@ -339,7 +339,7 @@ class Money { this.value = Number.parseFloat(value); this.currency = Currency.wrap(currency); if (!(bank instanceof Bank)) - throw new TypeError(`#{bank} is not an instance of Bank`); + throw new TypeError(`${bank} is not an instance of Bank`); this.bank = bank; } @@ -498,7 +498,7 @@ class Bank { exchange(money, to) { if (!(money instanceof Money)) - throw new TypeError(`#{money} is not an instance of Money`); + throw new TypeError(`${money} is not an instance of Money`); const toCurrency = Currency.wrap(to); if (toCurrency === money.currency) return money; @@ -523,7 +523,7 @@ class Money { this.value = Number.parseFloat(value); this.currency = Currency.wrap(currency); if (!(bank instanceof Bank)) - throw new TypeError(`#{bank} is not an instance of Bank`); + throw new TypeError(`${bank} is not an instance of Bank`); this.bank = bank; }