From 3ca913960d67b80d86a1f334224c4ebfbb0ced70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8E=89=E5=A2=9E=E4=BC=9F?= Date: Sat, 3 Oct 2020 09:21:07 +0800 Subject: [PATCH] =?UTF-8?q?=E6=81=A2=E5=A4=8D=20postJson=20=E7=94=A8?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Conversation/Client.php | 2 +- tests/Conversation/ClientTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Conversation/Client.php b/src/Conversation/Client.php index edc4a8e..7f1bd06 100644 --- a/src/Conversation/Client.php +++ b/src/Conversation/Client.php @@ -41,7 +41,7 @@ public function sendGeneralMessage($sender, $cid, $message) */ public function sendCorporationMessage($params) { - return $this->client->post('topapi/message/corpconversation/asyncsend_v2', $params); + return $this->client->postJson('topapi/message/corpconversation/asyncsend_v2', $params); } /** diff --git a/tests/Conversation/ClientTest.php b/tests/Conversation/ClientTest.php index 0d9eeb7..68d50ce 100644 --- a/tests/Conversation/ClientTest.php +++ b/tests/Conversation/ClientTest.php @@ -32,7 +32,7 @@ public function sendCorporationMessage() { $this->make(Client::class)->sendCorporationMessage($params = ['foo' => 'bar']) ->assertPostUri('topapi/message/corpconversation/asyncsend_v2') - ->assertPostFormParams($params); + ->assertPostJson($params); } /** @test */