public function delete($ids, \DatabaseTransaction $transaction = NULL) { $transaction = isset($transaction) ? $transaction : db_transaction(); try { parent::delete($ids, $transaction); db_delete('observers')->condition('observable_id', $ids, 'IN')->execute(); } catch (\Exception $e) { watchdog_exception($this->entityType, $e); $transaction->rollback(); throw $e; } }
/** * {@inheritdoc} */ public function delete($ids, \DatabaseTransaction $transaction = NULL) { if ($this->isFastDeleteEnabled()) { $this->fastDelete($ids, $transaction); return; } parent::delete($ids, $transaction); }