update rm deadcode
This commit is contained in:
@@ -5,7 +5,7 @@ namespace App\Http\Services;
|
||||
use App\Models\ModuleHosting;
|
||||
use App\Support\Eloquent\Sluggable;
|
||||
use Illuminate\Support\Facades\Crypt;
|
||||
use Illuminate\Support\Facades\Http;
|
||||
use App\Support\TlsHttpClientFactory;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ class Hosting
|
||||
|
||||
if ($apiCheck) {
|
||||
|
||||
return Http::withoutVerifying()
|
||||
return TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -47,7 +47,7 @@ class Hosting
|
||||
Log::info('Không tồn tại apiKey');
|
||||
return false;
|
||||
}
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -64,7 +64,7 @@ class Hosting
|
||||
*/
|
||||
public function LoginServer(): array
|
||||
{
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withBasicAuth($this->username, $this->password)
|
||||
->acceptJson()
|
||||
->post("https://$this->url/api/v2/auth/keys",
|
||||
@@ -127,7 +127,7 @@ class Hosting
|
||||
*/
|
||||
public function getAllClients()
|
||||
{
|
||||
return Http::withoutVerifying()
|
||||
return TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -137,7 +137,7 @@ class Hosting
|
||||
|
||||
public function CreateNewClient($product_data = [], $password = ''): array
|
||||
{
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -202,7 +202,7 @@ class Hosting
|
||||
|
||||
if ($apiCheck) {
|
||||
|
||||
$allDomain = Http::withoutVerifying()
|
||||
$allDomain = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -234,7 +234,7 @@ class Hosting
|
||||
|
||||
if ($apiCheck) {
|
||||
|
||||
$CreateDomain = Http::withoutVerifying()
|
||||
$CreateDomain = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -276,7 +276,7 @@ class Hosting
|
||||
|
||||
public function CreateExpirationForDomain($domain = '', $date_exp = '')
|
||||
{
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -303,7 +303,7 @@ class Hosting
|
||||
|
||||
public function SuspendAccount($account_id = 0): array
|
||||
{
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -322,7 +322,7 @@ class Hosting
|
||||
|
||||
public function ActivateAccount($account_id = 0): array
|
||||
{
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
@@ -341,7 +341,7 @@ class Hosting
|
||||
|
||||
public function ResetPassword($account_id = 0, $password = ''): array
|
||||
{
|
||||
$response = Http::withoutVerifying()
|
||||
$response = TlsHttpClientFactory::plesk()
|
||||
->withHeaders([
|
||||
'X-API-Key' => $this->apiKey,
|
||||
'accept' => 'application/json'
|
||||
|
||||
Reference in New Issue
Block a user