Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public function test_produce_creates_new_span()
private function produceMessage(
string $message,
?string $key = null,
array $headers = null,
?array $headers = null,
bool $produceWithoutHeaders = false
): void {
$conf = new Conf();
Expand All @@ -163,7 +163,7 @@ private function consumeMessage(): int|Message
{
$conf = new Conf();

$conf->setRebalanceCb(function (KafkaConsumer $kafka, $err, array $partitions = null) {
$conf->setRebalanceCb(function (KafkaConsumer $kafka, $err, ?array $partitions = null) {
switch ($err) {
case RD_KAFKA_RESP_ERR__ASSIGN_PARTITIONS:
$kafka->assign($partitions);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public function __construct($response)
$this->response = $response;
}

public function then(callable $onFulfilled = null, callable $onRejected = null): Promise
public function then(?callable $onFulfilled = null, ?callable $onRejected = null): Promise
{
$this->onFulfilled = $onFulfilled;
$this->onRejected = $onRejected;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ final class MongoDBInstrumentation
/**
* @param callable(object):?string $commandSerializer
*/
public static function register(callable $commandSerializer = null): void
public static function register(?callable $commandSerializer = null): void
{
$instrumentation = new CachedInstrumentation(
'io.opentelemetry.contrib.php.mongodb',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ class TestedDefaultNullClass
private $fooBar;
private $fooBaz;

public function __construct(string $fooBar, stdClass $fooBaz = null)
public function __construct(string $fooBar, ?stdClass $fooBaz = null)
{
$this->fooBar = $fooBar;
$this->fooBaz = $fooBaz;
Expand Down
Loading