diff --git a/php/1-bad-practices/src/terminating-the-execution.php b/php/1-bad-practices/src/terminating-the-execution.php index d8abd0f..b514b1f 100644 --- a/php/1-bad-practices/src/terminating-the-execution.php +++ b/php/1-bad-practices/src/terminating-the-execution.php @@ -5,9 +5,14 @@ class Checker { public function check_data( $data ) { if ( ! $data ) { - exit(); + $this->call_exit(); } // ... } + + protected function call_exit() { + + exit(); + } }