Skip to content

Commit e83a58a

Browse files
authored
Merge pull request #28 from event-engine/feature/php8.4-remove-deprecations
Remove php8.4 deprecations
2 parents 60552f5 + 10ab64d commit e83a58a

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/Index/RawSqlIndexCmd.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public static function fromArray(array $data): Index
3535
return new self($data['sql'], $data['name'] ?? null);
3636
}
3737

38-
public function __construct(string $sql, string $name = null)
38+
public function __construct(string $sql, ?string $name = null)
3939
{
4040
$this->sql = $sql;
4141
$this->name = $name;

src/PostgresDocumentStore.php

+7-7
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,12 @@ final class PostgresDocumentStore implements DocumentStore\DocumentStore
6161

6262
public function __construct(
6363
\PDO $connection,
64-
string $tablePrefix = null,
65-
string $docIdSchema = null,
64+
?string $tablePrefix = null,
65+
?string $docIdSchema = null,
6666
bool $transactional = true,
6767
bool $useMetadataColumns = false,
68-
FilterProcessor $filterProcessor = null,
69-
OrderByProcessor $orderByProcessor = null
68+
?FilterProcessor $filterProcessor = null,
69+
?OrderByProcessor $orderByProcessor = null
7070
) {
7171
$this->connection = $connection;
7272
$this->connection->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION);
@@ -633,7 +633,7 @@ public function getPartialDoc(string $collectionName, PartialSelect $partialSele
633633
/**
634634
* @inheritDoc
635635
*/
636-
public function filterDocs(string $collectionName, Filter $filter, int $skip = null, int $limit = null, OrderBy $orderBy = null): \Traversable
636+
public function filterDocs(string $collectionName, Filter $filter, ?int $skip = null, ?int $limit = null, ?OrderBy $orderBy = null): \Traversable
637637
{
638638
$filterClause = $this->filterProcessor->process($filter);
639639
$filterStr = $filterClause->clause();
@@ -670,7 +670,7 @@ public function filterDocs(string $collectionName, Filter $filter, int $skip = n
670670
/**
671671
* @inheritDoc
672672
*/
673-
public function findDocs(string $collectionName, Filter $filter, int $skip = null, int $limit = null, OrderBy $orderBy = null): \Traversable
673+
public function findDocs(string $collectionName, Filter $filter, ?int $skip = null, ?int $limit = null, ?OrderBy $orderBy = null): \Traversable
674674
{
675675
$filterClause = $this->filterProcessor->process($filter);
676676
$filterStr = $filterClause->clause();
@@ -704,7 +704,7 @@ public function findDocs(string $collectionName, Filter $filter, int $skip = nul
704704
}
705705
}
706706

707-
public function findPartialDocs(string $collectionName, PartialSelect $partialSelect, Filter $filter, int $skip = null, int $limit = null, OrderBy $orderBy = null): \Traversable
707+
public function findPartialDocs(string $collectionName, PartialSelect $partialSelect, Filter $filter, ?int $skip = null, ?int $limit = null, ?OrderBy $orderBy = null): \Traversable
708708
{
709709
$filterClause = $this->filterProcessor->process($filter);
710710
$filterStr = $filterClause->clause();

0 commit comments

Comments
 (0)