public function getHandle() { // If table is not enabled, return null to prevent enqueueing. $table = $this->getMixer() instanceof Library\DatabaseTableInterface ? $this->getMixer() : $this->getMixer()->getTable(); $needle = array('name' => $table->getBase(), 'component_name' => 'com_' . $table->getIdentifier()->package); return count($this->_tables->find($needle)) ? parent::getHandle() : null; }
public function getHandle() { $return = null; $mixer = $this->getMixer(); if ($mixer instanceof Library\DatabaseTableInterface || $mixer instanceof Library\DatabaseRowInterface || $mixer instanceof Library\DatabaseRowsetInterface) { // If table is not enabled, return null to prevent enqueueing. $table = $mixer instanceof Library\DatabaseTableInterface ? $mixer : $mixer->getTable(); $needle = array('name' => $table->getBase(), 'extension_name' => 'com_' . $table->getIdentifier()->package); if (count($this->_tables->find($needle))) { $return = parent::getHandle(); } } else { $return = parent::getHandle(); } return $return; }