Skip to content

Commit

Permalink
Removed insertid calls from installer adapters to avoid pitfalls rela…
Browse files Browse the repository at this point in the history
…ted to JTable::store
  • Loading branch information
carlopires committed Apr 4, 2012
1 parent bd747b5 commit a97e2ff
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 7 deletions.
2 changes: 1 addition & 1 deletion libraries/joomla/installer/adapters/component.php
Expand Up @@ -541,7 +541,7 @@ public function install()
return false;
}

$eid = $db->insertid();
$eid = $row->extension_id;

// Clobber any possible pending updates
$update = JTable::getInstance('update');
Expand Down
3 changes: 0 additions & 3 deletions libraries/joomla/installer/adapters/file.php
Expand Up @@ -254,9 +254,6 @@ public function install()
return false;
}

// Set the insert id
$row->set('extension_id', $db->insertid());

// Since we have created a module item, we add it to the installation step stack
// so that if we have to rollback the changes we can undo it.
$this->parent->pushStep(array('type' => 'extension', 'extension_id' => $row->extension_id));
Expand Down
3 changes: 0 additions & 3 deletions libraries/joomla/installer/adapters/module.php
Expand Up @@ -427,9 +427,6 @@ public function install()
return false;
}

// Set the insert id
$row->extension_id = $db->insertid();

// Since we have created a module item, we add it to the installation step stack
// so that if we have to rollback the changes we can undo it.
$this->parent->pushStep(array('type' => 'extension', 'extension_id' => $row->extension_id));
Expand Down

0 comments on commit a97e2ff

Please sign in to comment.