-
-
Notifications
You must be signed in to change notification settings - Fork 742
Closed
rectorphp/rector-src
#7843Labels
Description
Bug Report
| Subject | Details |
|---|---|
| Rector version | Rector 2.3.1 |
if ($this->lastInsertedId !== null && $result[\array_key_first($result)] === null) {
$result[\array_key_first($result)] = $this->lastInsertedId;
}
// ===>
if ($this->lastInsertedId !== null && array_first($result) === null) {
array_first($result) = $this->lastInsertedId;
}The expression array_first($result) cannot appear on the left-hand side.
Minimal PHP Code Causing Issue
Expected Behaviour
$result[\array_key_first($result)] = $this->lastInsertedId;Reactions are currently unavailable