Commit ef825779 authored by Alexander Butenko's avatar Alexander Butenko

Make get* protected to allow overloads

parent 9ad5d974
...@@ -297,7 +297,7 @@ class dbObject { ...@@ -297,7 +297,7 @@ class dbObject {
* *
* @return dbObject|array * @return dbObject|array
*/ */
private function byId ($id, $fields = null) { protected function byId ($id, $fields = null) {
$this->db->where (MysqliDb::$prefix . $this->dbTable . '.' . $this->primaryKey, $id); $this->db->where (MysqliDb::$prefix . $this->dbTable . '.' . $this->primaryKey, $id);
return $this->getOne ($fields); return $this->getOne ($fields);
} }
...@@ -310,7 +310,7 @@ class dbObject { ...@@ -310,7 +310,7 @@ class dbObject {
* *
* @return dbObject * @return dbObject
*/ */
private function getOne ($fields = null) { protected function getOne ($fields = null) {
$this->processHasOneWith (); $this->processHasOneWith ();
$results = $this->db->ArrayBuilder()->getOne ($this->dbTable, $fields); $results = $this->db->ArrayBuilder()->getOne ($this->dbTable, $fields);
if ($this->db->count == 0) if ($this->db->count == 0)
...@@ -340,7 +340,7 @@ class dbObject { ...@@ -340,7 +340,7 @@ class dbObject {
* *
* @return array Array of dbObjects * @return array Array of dbObjects
*/ */
private function get ($limit = null, $fields = null) { protected function get ($limit = null, $fields = null) {
$objects = Array (); $objects = Array ();
$this->processHasOneWith (); $this->processHasOneWith ();
$results = $this->db->ArrayBuilder()->get ($this->dbTable, $limit, $fields); $results = $this->db->ArrayBuilder()->get ($this->dbTable, $limit, $fields);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment