*** /home/brainstorm/work/drupal6_things/modules/node_images/node_images.module 2009-02-03 16:45:50.000000000 +0300 --- node_images.module 2009-04-23 11:22:14.000000000 +0400 *************** function node_images_nodeapi(&$node, $op *** 203,210 **** --- 203,214 ---- while ($r = db_fetch_object($sql)) { file_delete($r->filepath); file_delete($r->thumbpath); + if(module_exists('imagecache') ){ + imagecache_image_flush($r->filepath); + } module_invoke('i18nstrings', 'remove_string', _node_images_build_i18nstrings_context($r)); } + cache_clear_all(); // Delete all images associated with the node db_query('DELETE FROM {node_images} WHERE nid=%d', $node->nid); break; *************** function _node_images_file_upload($form, *** 454,460 **** if ($file = file_save_upload($source, $validators, $dest)) { // remove uploaded file from the files table, so it won't be deleted by system_cron() db_query('DELETE FROM {files} WHERE fid = %d', $file->fid); ! return $file; } --- 458,464 ---- if ($file = file_save_upload($source, $validators, $dest)) { // remove uploaded file from the files table, so it won't be deleted by system_cron() db_query('DELETE FROM {files} WHERE fid = %d', $file->fid); ! cache_clear_all(); return $file; } *************** function _node_images_save_attachments(& *** 539,544 **** --- 543,552 ---- } else { file_delete($file->filepath); + if(module_exists('imagecache') ){ + imagecache_image_flush($file->filepath); + } + cache_clear_all(); db_query('DELETE FROM {files} WHERE fid = %d', $fid); // Remove it from the session in the case of new uploads, *************** function _node_images_translate(&$file, *** 983,986 **** if (module_exists('i18nstrings') && function_exists('tt')) { $file->description = tt($context, $file->description, NULL, $update); } ! } \ В конце файла нет новой строки --- 991,994 ---- if (module_exists('i18nstrings') && function_exists('tt')) { $file->description = tt($context, $file->description, NULL, $update); } ! }