Skip to content

Commit ebb8e26

Browse files
authored
Merge pull request #6711 from paulbalandan/prepared-query-interface
Match signature of `PreparedQueryInterface::close()` to `BasePreparedQuery::close()`
2 parents 0831f15 + b6b7f4f commit ebb8e26

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

system/Database/PreparedQueryInterface.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111

1212
namespace CodeIgniter\Database;
1313

14+
use BadMethodCallException;
15+
1416
/**
1517
* Prepared query interface
1618
*
@@ -36,8 +38,10 @@ public function prepare(string $sql, array $options = []);
3638

3739
/**
3840
* Explicity closes the statement.
41+
*
42+
* @throws BadMethodCallException
3943
*/
40-
public function close();
44+
public function close(): bool;
4145

4246
/**
4347
* Returns the SQL that has been prepared.

user_guide_src/source/changelogs/v4.3.0.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ The return value of ``Validation::loadRuleGroup()`` has been changed ``null`` t
9090
Others
9191
------
9292

93-
- The return type of ``CodeIgniter\Database\BasePreparedQuery::close()`` has been changed to ``bool``.
93+
- The return types of ``CodeIgniter\Database\BasePreparedQuery::close()`` and ``CodeIgniter\Database\PreparedQueryInterface`` have been changed to ``bool`` (previously untyped).
9494
- The return type of ``CodeIgniter\Database\Database::loadForge()`` has been changed to ``Forge``.
9595
- The return type of ``CodeIgniter\Database\Database::loadUtils()`` has been changed to ``BaseUtils``.
9696
- Parameter ``$column`` has changed in ``Table::dropForeignKey()`` to ``$foreignName``.

0 commit comments

Comments
 (0)