Fixing CakeFixtureManager::loadSingle to create the table if not exists

This commit is contained in:
José Lorenzo Rodríguez 2010-05-31 23:49:18 -04:30
parent 82da9be2ce
commit c4b35ebc14

View file

@ -43,7 +43,7 @@ class CakeFixtureManager {
protected $_loaded = array();
/**
* Holds the fixture classes that where instantiated indexed by class name
* Holds the fixture classes that where ins tantiated indexed by class name
*
* @var array
*/
@ -260,6 +260,7 @@ class CakeFixtureManager {
$db = $this->_db;
}
$fixture = $this->_fixtureMap[$name];
$this->_setupTable($fixture, $db);
$fixture->truncate($db);
$fixture->insert($db);
} else {