Skip to content

Commit

Permalink
fix: preparedId is nullable (#516)
Browse files Browse the repository at this point in the history
  • Loading branch information
JoyceBabu authored Feb 4, 2023
1 parent cd5e33f commit 17dcf3f
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/DebugBar/DataCollector/PDO/TracedStatement.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,14 @@ class TracedStatement

protected $exception;

protected $preparedId;

/**
* @param string $sql
* @param array $params
* @param string $preparedId
* @param null|string $preparedId
*/
public function __construct(string $sql, array $params = [], $preparedId = null)
public function __construct(string $sql, array $params = [], ?string $preparedId = null)
{
$this->sql = $sql;
$this->parameters = $this->checkParameters($params);
Expand Down Expand Up @@ -164,9 +166,9 @@ public function getParameters() : array
/**
* Returns the prepared statement id
*
* @return string
* @return null|string
*/
public function getPreparedId() : string
public function getPreparedId() : ?string
{
return $this->preparedId;
}
Expand Down

0 comments on commit 17dcf3f

Please sign in to comment.