From 0d9beedd0b0a7511f21320984016fcacf55398e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96tv=C3=B6s=20Rich=C3=A1rd?= Date: Thu, 2 May 2019 14:40:14 +0200 Subject: [PATCH 1/2] Fixes typo in method name I guess this should be 'profit'. Is there other places I should change this? --- src/static/patterns/behavioral_observer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/static/patterns/behavioral_observer.js b/src/static/patterns/behavioral_observer.js index 2d29fd5..592db36 100644 --- a/src/static/patterns/behavioral_observer.js +++ b/src/static/patterns/behavioral_observer.js @@ -83,13 +83,13 @@ class fees { } } -class proft { +class profit { update(product) { product.price = product.price * 2; } } -export { Product, fees, proft };` +export { Product, fees, profit };` }; export default OBSERVER; From a41bb9312f1f66478eb734d6b39724297b16aa68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=96tv=C3=B6s=20Rich=C3=A1rd?= Date: Thu, 2 May 2019 17:11:25 +0200 Subject: [PATCH 2/2] Fixes the other two typos --- src/static/patterns/behavioral_observer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/static/patterns/behavioral_observer.js b/src/static/patterns/behavioral_observer.js index 592db36..cee093b 100644 --- a/src/static/patterns/behavioral_observer.js +++ b/src/static/patterns/behavioral_observer.js @@ -40,13 +40,13 @@ var fees = { } }; -var proft = { +var profit = { update: function(product) { product.price = product.price * 2; } }; -module.exports = [Product, fees, proft];`, +module.exports = [Product, fees, profit];`, codeES6: `class Product { constructor() { this.price = 0;