Adding missing loadModel() (ticket #2058)

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4453 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
dho 2007-02-05 12:49:35 +00:00
parent 24d65cafbc
commit 80e503a70f

View file

@ -434,6 +434,7 @@ class Bake {
$wannaDoValidation = $this->getInput('Would you like to supply validation criteria for the fields in your model?', array('y','n'), 'y'); $wannaDoValidation = $this->getInput('Would you like to supply validation criteria for the fields in your model?', array('y','n'), 'y');
if(array_search($useTable, $this->__tables)) { if(array_search($useTable, $this->__tables)) {
loadModel();
$tempModel = new Model(false, $useTable); $tempModel = new Model(false, $useTable);
$db =& ConnectionManager::getDataSource($useDbConfig); $db =& ConnectionManager::getDataSource($useDbConfig);
$modelFields = $db->describe($tempModel); $modelFields = $db->describe($tempModel);