Skip to content

Commit 2d4198c

Browse files
task: Proper type hint for Lock::run()
1 parent 7963bd4 commit 2d4198c

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

Classes/Lock.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ public function __construct(int $numberOfWorkers, string $lockFileDirectory)
3030
}
3131
}
3232

33+
/**
34+
* @template T
35+
* @param callable(): T $run
36+
* @return T
37+
*/
3338
public function run(callable $run)
3439
{
3540
$this->findSlot();

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"flowpack/jobqueue-common": "^3.0.0",
1414
"netlogix/supervisor": "^1.0",
1515
"php-amqplib/php-amqplib": "^2.11",
16-
"t3n/jobqueue-rabbitmq": "^2.3.0"
16+
"t3n/jobqueue-rabbitmq": "^2.3.0",
17+
"php": "~8.2 || ~8.3 || ~8.4"
1718
},
1819
"extra": {
1920
"neos": {

0 commit comments

Comments
 (0)