diff --git a/app/Libraries/MySocket/WebLibrary.php b/app/Libraries/MySocket/WebLibrary.php index ccd2c30..9975e55 100644 --- a/app/Libraries/MySocket/WebLibrary.php +++ b/app/Libraries/MySocket/WebLibrary.php @@ -67,11 +67,12 @@ class WebLibrary extends MySocketLibrary } log_message("debug", "Socket URL-> " . $url); $response = $this->getClient()->get($url, $options); - if ($response->getStatusCode() != 200) { + if ($response->getStatusCode() == 200) { + return $response->getBody()->getContents(); + // return $response->getBody(); + } else { throw new \Exception("error", "{$url} 접속실패: " . $response->getStatusCode()); } - // return $response->getBody()->getContents(); - return $response->getBody(); } // 로그인 메서드