Skip to content

Commit 4bdb0a6

Browse files
authored
chore: drop support for PHP 7.4 (#558)
1 parent e9690f5 commit 4bdb0a6

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

.github/workflows/tests.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
strategy:
1212
matrix:
13-
php: [ "7.4", "8.0", "8.1", "8.2", "8.3" ]
13+
php: [ "8.0", "8.1", "8.2", "8.3" ]
1414
name: PHP ${{matrix.php }} Unit Test
1515
steps:
1616
- uses: actions/checkout@v2

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ composer require firebase/php-jwt
1717
```
1818

1919
Optionally, install the `paragonie/sodium_compat` package from composer if your
20-
php is < 7.2 or does not have libsodium installed:
20+
php env does not have libsodium installed:
2121

2222
```bash
2323
composer require paragonie/sodium_compat

composer.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
],
2121
"license": "BSD-3-Clause",
2222
"require": {
23-
"php": "^7.4||^8.0"
23+
"php": "^8.0"
2424
},
2525
"suggest": {
2626
"paragonie/sodium_compat": "Support EdDSA (Ed25519) signatures when libsodium is not present",
@@ -32,10 +32,10 @@
3232
}
3333
},
3434
"require-dev": {
35-
"guzzlehttp/guzzle": "^6.5||^7.4",
35+
"guzzlehttp/guzzle": "^7.4",
3636
"phpspec/prophecy-phpunit": "^2.0",
3737
"phpunit/phpunit": "^9.5",
38-
"psr/cache": "^1.0||^2.0",
38+
"psr/cache": "^2.0||^3.0",
3939
"psr/http-client": "^1.0",
4040
"psr/http-factory": "^1.0"
4141
}

tests/CachedKeySetTest.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -553,7 +553,7 @@ public function getKey(): string
553553
return $this->key;
554554
}
555555

556-
public function get()
556+
public function get(): mixed
557557
{
558558
return $this->isHit() ? $this->value : null;
559559
}
@@ -571,21 +571,21 @@ public function isHit(): bool
571571
return $this->currentTime()->getTimestamp() < $this->expiration->getTimestamp();
572572
}
573573

574-
public function set($value)
574+
public function set(mixed $value): static
575575
{
576576
$this->isHit = true;
577577
$this->value = $value;
578578

579579
return $this;
580580
}
581581

582-
public function expiresAt($expiration)
582+
public function expiresAt($expiration): static
583583
{
584584
$this->expiration = $expiration;
585585
return $this;
586586
}
587587

588-
public function expiresAfter($time)
588+
public function expiresAfter($time): static
589589
{
590590
$this->expiration = $this->currentTime()->add(new \DateInterval("PT{$time}S"));
591591
return $this;

0 commit comments

Comments
 (0)