Skip to content

Commit

Permalink
PDO firebird: remove unnecessary methods
Browse files Browse the repository at this point in the history
- _init() did not actually initialize anything useful, as the
  $pdoDriver property was not used anywhere.
- _affectedrows() was likely introduced by mistake (copy/paste error
  when the driver was refactored in 2019), as it references Firebird
  native (non-PDO) function fbird_affected_rows(), as discussed in
  ADOdb#935.

This fixes PHP 8.2 deprecation warnings due to undefined properties.
  • Loading branch information
dregad committed Mar 17, 2023
1 parent f52cf8a commit 5766f6b
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions drivers/adodb-pdo_firebird.inc.php
Expand Up @@ -32,14 +32,6 @@ class ADODB_pdo_firebird extends ADODB_pdo

var $arrayClass = 'ADORecordSet_array_pdo_firebird';

function _init($parentDriver)
{
$this->pdoDriver = $parentDriver;
//$parentDriver->_bindInputArray = true;
//$parentDriver->hasTransactions = false; // // should be set to false because of PDO SQLite driver not supporting changing autocommit mode
//$parentDriver->hasInsertID = true;
}

/**
* Gets the version iformation from the server
*
Expand Down Expand Up @@ -243,12 +235,6 @@ public function dropSequence($seqname = 'adodbseq')
return $this->Execute("DROP SEQUENCE $seqname");
}


public function _affectedrows()
{
return fbird_affected_rows($this->_transactionID ? $this->_transactionID : $this->_connectionID);
}

public function genId($seqname = 'adodbseq', $startID = 1)
{
$getnext = ("SELECT Gen_ID($seqname,1) FROM RDB\$DATABASE");
Expand Down

0 comments on commit 5766f6b

Please sign in to comment.