Skip to content

Commit

Permalink
Fix issue jrbasso#7 - delete file bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jrbasso committed Aug 24, 2009
1 parent 6e15b56 commit f621d4b
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions models/behaviors/meio_upload.php
Expand Up @@ -1077,13 +1077,12 @@ function _markForDeletion($modelName, $modelPrimaryKey, $fieldName, $data, $defa
if ($default) {
$data[$modelName][$fieldName] = $default;
} else {
$data[$modelName][$fieldName] = null;
$data[$modelName][$fieldName] = '';
}
//if the record is already saved in the database, set the existing file to be removed after the save is sucessfull
if (!empty($data[$modelName][$modelPrimaryKey])) {
$this->_setFileToRemove($fieldName);
}
continue;
}
}

Expand Down

0 comments on commit f621d4b

Please sign in to comment.