Skip to content

Commit 8893e21

Browse files
authored
Merge pull request #150 from xav-developer/fix/strict-types
The "withHeader" method expects the type "string|iterable", "int" is passed
2 parents 2207f31 + 4889d7f commit 8893e21

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog][keepachangelog] and this project adheres to [Semantic Versioning][semver].
66

7+
### Fixed
8+
9+
- The "withHeader" method of the "\Spiral\RoadRunner\Jobs\Task\WritableHeadersInterface" interface expects the type "string|iterable", "int" is passed
10+
711
## v5.12.0
812

913
### Added

src/Queue/RoadRunnerJob.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ protected function failed($e): void
5353
$attempts = $this->attempts();
5454

5555
$this->task
56-
->withHeader('attempts', $attempts + 1)
56+
->withHeader('attempts', (string) ++$attempts)
5757
->fail($e->getMessage());
5858

5959
parent::failed($e);

0 commit comments

Comments
 (0)