We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 11205cb commit ff48fa4Copy full SHA for ff48fa4
src/BaseClient.php
@@ -143,13 +143,16 @@ public function sendHttpRequest(): self {
143
public function requestSent(): bool {
144
return $this->request_sent;
145
}
146
+ protected function getRequestLogContent(): string {
147
+ return $this->client->__toString();
148
+ }
149
protected function recv(): \Swlib\Saber\Response {
150
if (! $this->request_sent) {
151
throw new \Exception('Request not sent');
152
153
$client = $this->client;
154
$log_string = date('[Y-m-d H:i:s] ', $this->send_time) . "----------Request----------\n";
- $log_string .= $client->__toString() . "\n";
155
+ $log_string .= $this->getRequestLogContent() . "\n";
156
try {
157
$response = $client->recv();
158
$code = $response->statusCode;
0 commit comments