When I first try it, it did not create the table as I expected (initialized with createTable => true and tableName => ‘config’).
I had to modify the init() method by changing the order between the first 2 tests :
This is the result and it works fine :
public function init()
{
// do this first ...
if($this->getCreateTable())
$this->createTable();
// ... and then load items
if($this->getLoadDbItems())
$this->loadDbItems();
$this->_initialized=true;
Yii::app()->attachEventHandler('onEndRequest', array($this,'whenRequestEnds'));
}
Is there something I didn’t do well or did I fix a bug ?