git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6878 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
the_undefined 2008-05-15 04:00:21 +00:00
parent ea9e91218e
commit 52245a059f
2 changed files with 2 additions and 2 deletions

View file

@ -221,9 +221,8 @@ class TranslateBehavior extends ModelBehavior {
/**
* Callback
*/
function beforeSave(&$model) {
function beforeValidate(&$model) {
$locale = $this->_getLocale($model);
if (empty($locale)) {
return true;
}

View file

@ -378,6 +378,7 @@ class TranslateTest extends CakeTestCase {
function testMultipleUpdate() {
$this->Model->locale = 'eng';
$this->Model->validate['title'] = VALID_NOT_EMPTY;
$data = array('TranslatedItem' => array(
'id' => 1,
'title' => array('eng' => 'New Title #1', 'deu' => 'Neue Titel #1', 'cze' => 'Novy Titulek #1'),