diff --git a/CHANGELOG.md b/CHANGELOG.md index 4eebcfb0f..f412a938e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,11 +2,12 @@ ## 1.1.1 under development -- no changes in this release. +- New #617: Add debug collector for `yiisoft/yii-debug` (@xepozz) +- Enh #617, #733: Add specific psalm annotation of `$closure` parameter in `ConnectionInterface::transaction()` + method (@xepozz, @vjik) ## 1.1.0 July 24, 2023 -- Enh #617: Add debug collector for yiisoft/yii-debug (@xepozz) - Chg #722: Remove legacy array syntax for typecast. Use `Param` instead (@terabytesoftw) - Chg #724: Typecast refactoring (@Tigrov) - Chg #728: Refactor `AbstractSchema::getColumnPhpType()` (@Tigrov) diff --git a/src/Connection/ConnectionInterface.php b/src/Connection/ConnectionInterface.php index c4f2e24d6..596a5df24 100644 --- a/src/Connection/ConnectionInterface.php +++ b/src/Connection/ConnectionInterface.php @@ -212,13 +212,15 @@ public function setTablePrefix(string $value): void; /** * Executes callback provided in a transaction. * - * @psalm-param Closure(ConnectionInterface): mixed $closure A valid PHP callback that performs the job. Accepts connection instance as parameter. + * @param Closure $closure A valid PHP callback that performs the job. Accepts connection instance as parameter. * @param string|null $isolationLevel The isolation level to use for this transaction. * {@see TransactionInterface::begin()} for details. * * @throws Throwable If there is any exception during query. In this case, the transaction will be rolled back. * * @return mixed Result of callback function. + * + * @psalm-param Closure(ConnectionInterface):mixed|Closure(ConnectionInterface):void $closure */ public function transaction(Closure $closure, string $isolationLevel = null): mixed; }