code: public function delete()
  	{
  		$intPk = $this->{static::$strPk};
  
  		// Track primary key changes
  		if (isset($this->arrModified[static::$strPk]))
  		{
  			$intPk = $this->arrModified[static::$strPk];
  		}
  
  		// Delete the row
  		$intAffected = Database::getInstance()->prepare("DELETE FROM " . static::$strTable . " WHERE " . Database::quoteIdentifier(static::$strPk) . "=?")
  											   ->execute($intPk)
  											   ->affectedRows;
  
  		if ($intAffected)
  		{
  			// Unregister the model
  			Registry::getInstance()->unregister($this);
  
  			// Remove the primary key (see #6162)
  			$this->arrData[static::$strPk] = null;
  		}
  
  		return $intAffected;
  	}
docs: Delete the current record and return the number of affected rows
  
  @return integer The number of affected rows