Skip to content

Commit dab03f9

Browse files
fix job for json encode/decode
1 parent c8d7ee1 commit dab03f9

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/VladimirYuldashev/LaravelQueueRabbitMQ/Queue/Jobs/RabbitMQJob.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,13 @@ public function fire()
4848
*/
4949
public function getRawBody()
5050
{
51-
$body = json_decode($this->message->body, true);
52-
51+
$body = $this->message->body;
52+
53+
$body = json_decode($body, true);
54+
5355
unset($body['data']['attempts']);
54-
55-
return $body;
56+
57+
return json_encode($body);
5658
}
5759

5860
/**

0 commit comments

Comments
 (0)