mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-08-28 13:58:53 +02:00
Fix deprecations (#4636)
* Fix PHP 8.4 deprecation Implicitly marking parameter as nullable is deprecated, the explicit nullable type must be used instead * [github workflow] Add additional php versions
This commit is contained in:
parent
c65fbd5543
commit
a2334838a6
10 changed files with 12 additions and 12 deletions
|
@ -12,7 +12,7 @@ class CacheFactory
|
|||
$this->logger = $logger;
|
||||
}
|
||||
|
||||
public function create(string $name = null): CacheInterface
|
||||
public function create(?string $name = null): CacheInterface
|
||||
{
|
||||
$cacheNames = [];
|
||||
foreach (scandir(PATH_LIB_CACHES) as $file) {
|
||||
|
|
|
@ -4,7 +4,7 @@ interface CacheInterface
|
|||
{
|
||||
public function get(string $key, $default = null);
|
||||
|
||||
public function set(string $key, $value, int $ttl = null): void;
|
||||
public function set(string $key, $value, ?int $ttl = null): void;
|
||||
|
||||
public function delete(string $key): void;
|
||||
|
||||
|
|
|
@ -227,7 +227,7 @@ final class Request
|
|||
return $this->get[$key] ?? $default;
|
||||
}
|
||||
|
||||
public function server(string $key, string $default = null): ?string
|
||||
public function server(string $key, ?string $default = null): ?string
|
||||
{
|
||||
return $this->server[$key] ?? $default;
|
||||
}
|
||||
|
|
|
@ -712,7 +712,7 @@ class Parsedown
|
|||
#
|
||||
# Setext
|
||||
|
||||
protected function blockSetextHeader($Line, array $Block = null)
|
||||
protected function blockSetextHeader($Line, ?array $Block = null)
|
||||
{
|
||||
if ( ! isset($Block) or isset($Block['type']) or isset($Block['interrupted']))
|
||||
{
|
||||
|
@ -850,7 +850,7 @@ class Parsedown
|
|||
#
|
||||
# Table
|
||||
|
||||
protected function blockTable($Line, array $Block = null)
|
||||
protected function blockTable($Line, ?array $Block = null)
|
||||
{
|
||||
if ( ! isset($Block) or isset($Block['type']) or isset($Block['interrupted']))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue