From 74caf083baf85c2143bcf243f12fcfd197d26677 Mon Sep 17 00:00:00 2001 From: tacodes <64085493+tim-andes@users.noreply.github.com> Date: Fri, 30 Apr 2021 13:44:00 -0600 Subject: [PATCH] Add/remove commas for readability --- pages/Design-Patterns.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/Design-Patterns.md b/pages/Design-Patterns.md index 7bf4f5e..6121dd0 100644 --- a/pages/Design-Patterns.md +++ b/pages/Design-Patterns.md @@ -54,8 +54,8 @@ print_r($veyron->getMakeAndModel()); // outputs "Bugatti Veyron" This code uses a factory to create the Automobile object. There are two possible benefits to building your code this way; the first is that if you need to change, rename, or replace the Automobile class later on you can do so and you will only have to modify the code in the factory, instead of every place in your project that uses the Automobile class. -The second possible benefit is that if creating the object is a complicated job you can do all of the work in the -factory, instead of repeating it every time you want to create a new instance. +The second possible benefit is that, if creating the object is a complicated job, you can do all of the work in the +factory instead of repeating it every time you want to create a new instance. Using the factory pattern isn't always necessary (or wise). The example code used here is so simple that a factory would simply be adding unneeded complexity. However if you are making a fairly large or complex project you may save