summaryrefslogtreecommitdiffstats
path: root/user_guide_src
diff options
context:
space:
mode:
authorTomaz Lovrec <tomaz.lovrec@gmail.com>2016-12-16 13:00:19 +0100
committerTomaz Lovrec <tomaz.lovrec@gmail.com>2016-12-16 13:00:19 +0100
commit468d16a24f2ecd07e922e158f541e9f6831636f2 (patch)
tree71f68839bf0eb53b09d58b78ba98c59761e78c4d /user_guide_src
parentfacb347dcb5fe6f32d2c57fbe24db59d11a3ab6d (diff)
Remove needless constructor in model documentation
PHP will execute the parent constructor regardless if a constructor method is defined in the child class or not. Defining an empty constructor just to call the parents constructor can be considered bad practice.
Diffstat (limited to 'user_guide_src')
-rw-r--r--user_guide_src/source/general/models.rst6
1 files changed, 0 insertions, 6 deletions
diff --git a/user_guide_src/source/general/models.rst b/user_guide_src/source/general/models.rst
index 1cfe736de..08e9f5b30 100644
--- a/user_guide_src/source/general/models.rst
+++ b/user_guide_src/source/general/models.rst
@@ -22,12 +22,6 @@ model class might look like::
public $content;
public $date;
- public function __construct()
- {
- // Call the CI_Model constructor
- parent::__construct();
- }
-
public function get_last_ten_entries()
{
$query = $this->db->get('entries', 10);