HEX
Server: Apache
System: Linux 4801f1b1.ptr.provps.com 6.17.8-1.el9.elrepo.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Nov 13 18:02:25 EST 2025 x86_64
User: nassaugo (1004)
PHP: 8.1.34
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/nassaugo/www/wp-content/plugins/wp-all-import-pro/src/Scheduling/Connection.php
<?php

namespace Wpai\Scheduling;

/**
 * Class Connection
 * @package Wpai\Scheduling
 */
class Connection
{
    /**
     * @return bool
     */
    public function checkConnection()
   {
       $response = wp_remote_request(

           $this->getApiUrl('connection'),
           array(
               'method' => 'GET',
               'body' => \json_encode(array(get_site_url('/wp-load.php')))
           )
       );

       if($response instanceof \WP_Error) {
           return false;
       }

       if ($response['response']['code'] == 200) {
           return true;
       } else {
           return false;
       }
   }
}