Visual Console Refactor: minor fix
Former-commit-id: 4350b8342f0a813c7283bd8a2bf2a3a76b677c5a
This commit is contained in:
parent
e93cb8f9e7
commit
ab793257ad
|
@ -179,7 +179,7 @@ final class Container extends Model
|
||||||
*
|
*
|
||||||
* @override Model::fetchDataFromDB.
|
* @override Model::fetchDataFromDB.
|
||||||
*/
|
*/
|
||||||
public static function fetchDataFromDB(array $filter)
|
protected static function fetchDataFromDB(array $filter)
|
||||||
{
|
{
|
||||||
// Due to this DB call, this function cannot be unit tested without
|
// Due to this DB call, this function cannot be unit tested without
|
||||||
// a proper mock.
|
// a proper mock.
|
||||||
|
@ -189,8 +189,7 @@ final class Container extends Model
|
||||||
throw new \Exception('error fetching the data from the DB');
|
throw new \Exception('error fetching the data from the DB');
|
||||||
}
|
}
|
||||||
|
|
||||||
// New instance.
|
return $row;
|
||||||
return new static($row);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue