Skip to content
Permalink
Browse files

Set debug=2 when bake is run.

This should help with model caches being re-used when they shouldn't.
Fixes #2063
  • Loading branch information...
markstory committed Oct 5, 2011
1 parent cb1ce83 commit e56a2cdb2b1dfe397b387388dd6a4d29245df297
Showing with 3 additions and 1 deletion.
  1. +1 −0 lib/Cake/Console/Command/BakeShell.php
  2. +2 −1 lib/Cake/Console/Command/Task/BakeTask.php
@@ -65,6 +65,7 @@ public function startup() {
* @return mixed
*/
public function main() {
Configure::write('debug', 2);
Configure::write('Cache.disable', 1);
if (!is_dir($this->DbConfig->path)) {
@@ -46,12 +46,13 @@ class BakeTask extends Shell {
public $interactive = false;
/**
* Disable caching for baking.
* Disable caching and enable debug for baking.
* This forces the most current database schema to be used.
*
* @return void
*/
function startup() {
Configure::write('debug', 2);
Configure::write('Cache.disable', 1);
parent::startup();
}

0 comments on commit e56a2cd

Please sign in to comment.
You can’t perform that action at this time.