fixed recursive update when deleting in indices

This commit is contained in:
real_nowhereman 2008-09-19 17:09:53 +00:00
parent 993c58fc4e
commit 9c967770eb

View File

@ -125,8 +125,9 @@
$main =& $this->get_index();
$main->delitem($key);
if (isset($entry['CATEGORIES']) && is_array($entry['CATEGORIES'])) {
foreach ($entry['CATEGORIES'] as $cat) {
$entry = entry_parse($id);
if (isset($entry['categories']) && is_array($entry['categories'])) {
foreach ($entry['categories'] as $cat) {
if (!is_numeric($cat)) continue;
$this_index =& $this->get_index($cat);
$this_index->delitem($key);
@ -639,7 +640,7 @@
if (!io_write_file($f, $str)) {
if ($update_index)
$obj->delete($id);
$obj->delete($id, $entry);
return false;
} else return $id;