diff --git a/system/CodeIgniter.php b/system/CodeIgniter.php
index <HASH>..<HASH> 100644
--- a/system/CodeIgniter.php
+++ b/system/CodeIgniter.php
@@ -326,6 +326,7 @@ class CodeIgniter
 
 			$this->response->pretend($this->useSafeOutput)->send();
 			$this->callExit(EXIT_SUCCESS);
+			return;
 		}
 
 		try
@@ -343,6 +344,7 @@ class CodeIgniter
 			$this->sendResponse();
 
 			$this->callExit(EXIT_SUCCESS);
+			return;
 		}
 		catch (PageNotFoundException $e)
 		{
refactor: add return not to run code below when testing