|
|
@@ -26,8 +26,7 @@ class customConsumer implements ConsumerInterface
|
|
|
{
|
|
|
try {
|
|
|
// 反序列化消息体
|
|
|
- $data = json_decode($msg->body, true);
|
|
|
-
|
|
|
+ $data = unserialize($msg->body);
|
|
|
if (!is_array($data)) {
|
|
|
Yii::error("Invalid custom message format: {$msg->body}", 'rabbitmq.custom');
|
|
|
return ConsumerInterface::MSG_REJECT;
|