Skip to content

Commit d8a7c12

Browse files
committed
updated
the formatting
1 parent eb1a585 commit d8a7c12

2 files changed

Lines changed: 21 additions & 18 deletions

File tree

src/Plesk.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,10 @@ public function curlInit($host, $login, $password)
5454
curl_setopt($this->curl, CURLOPT_POST, true);
5555
curl_setopt($this->curl, CURLOPT_SSL_VERIFYPEER, false);
5656
curl_setopt($this->curl, CURLOPT_SSL_VERIFYHOST, false);
57-
curl_setopt($this->curl, CURLOPT_HTTPHEADER, [
57+
curl_setopt(
58+
$this->curl,
59+
CURLOPT_HTTPHEADER,
60+
[
5861
"HTTP_AUTH_LOGIN: {$login}",
5962
"HTTP_AUTH_PASSWD: {$password}",
6063
'HTTP_PRETTY_PRINT: TRUE',

src/Plugin.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public static function getActivate(GenericEvent $event)
5252
{
5353
if ($event['category'] == get_service_define('WEB_PLESK')) {
5454
$serviceClass = $event->getSubject();
55-
myadmin_log(self::$module, 'info', 'Plesk Activation', __LINE__, __FILE__, self::$module, $serviceClass->getId());
55+
myadmin_log(self::$module, 'info', 'Plesk Activation', __LINE__, __FILE__, self::$module, $serviceClass->getId());
5656
$settings = get_module_settings(self::$module);
5757
$serverdata = get_service_master($serviceClass->getServer(), self::$module);
5858
$ip = $serverdata[$settings['PREFIX'].'_ip'];
@@ -302,7 +302,7 @@ function_requirements('get_webhosting_plesk_instance');
302302
public static function getDeactivate(GenericEvent $event)
303303
{
304304
if ($event['category'] == get_service_define('WEB_PLESK')) {
305-
$serviceClass = $event->getSubject();
305+
$serviceClass = $event->getSubject();
306306
myadmin_log(self::$module, 'info', 'Plesk Deactivation', __LINE__, __FILE__, self::$module, $serviceClass->getId());
307307
$serverdata = get_service_master($serviceClass->getServer(), self::$module);
308308
function_requirements('get_webhosting_plesk_instance');
@@ -328,7 +328,7 @@ public static function getTerminate(GenericEvent $event)
328328
{
329329
if ($event['category'] == get_service_define('WEB_PLESK')) {
330330
$event->stopPropagation();
331-
$serviceClass = $event->getSubject();
331+
$serviceClass = $event->getSubject();
332332
myadmin_log(self::$module, 'info', 'Plesk Termination', __LINE__, __FILE__, self::$module, $serviceClass->getId());
333333
$extra = run_event('parse_service_extra', $serviceClass->getExtra(), self::$module);
334334
$serverdata = get_service_master($serviceClass->getServer(), self::$module);
@@ -351,15 +351,15 @@ function_requirements('get_webhosting_plesk_instance');
351351
$request = ['id' => $subscriptoinId];
352352
try {
353353
$result = $plesk->deleteSubscription($request);
354-
myadmin_log(self::$module, 'info', 'deleteSubscription Called got '.json_encode($result), __LINE__, __FILE__, self::$module, $serviceClass->getId());
354+
myadmin_log(self::$module, 'info', 'deleteSubscription Called got '.json_encode($result), __LINE__, __FILE__, self::$module, $serviceClass->getId());
355355
} catch (\Exception $e) {
356356
myadmin_log('plesk', 'error', 'deleteSubscription id:'.$subscriptoinId.' Caught exception: '.$e->getMessage(), __LINE__, __FILE__, self::$module, $serviceClass->getId());
357357
echo 'Caught exception: '.$e->getMessage().PHP_EOL;
358358
}
359359
$request = ['id' => $userId];
360360
try {
361361
$result = $plesk->deleteClient($request);
362-
myadmin_log(self::$module, 'info', 'deleteClient Called got '.json_encode($result), __LINE__, __FILE__, self::$module, $serviceClass->getId());
362+
myadmin_log(self::$module, 'info', 'deleteClient Called got '.json_encode($result), __LINE__, __FILE__, self::$module, $serviceClass->getId());
363363
} catch (\Exception $e) {
364364
myadmin_log('plesk', 'error', 'deleteClient id:'.$userId.' Caught exception: '.$e->getMessage(), __LINE__, __FILE__, self::$module, $serviceClass->getId());
365365
echo 'Caught exception: '.$e->getMessage().PHP_EOL;
@@ -411,25 +411,25 @@ public static function getMenu(GenericEvent $event)
411411
*/
412412
public static function getRequirements(GenericEvent $event)
413413
{
414-
/**
415-
* @var \MyAdmin\Plugins\Loader $this->loader
416-
*/
417-
$loader = $event->getSubject();
414+
/**
415+
* @var \MyAdmin\Plugins\Loader $this->loader
416+
*/
417+
$loader = $event->getSubject();
418418
$loader->add_requirement('get_webhosting_plesk_instance', '/../vendor/detain/myadmin-plesk-webhosting/src/get_webhosting_plesk_instance.php');
419419
}
420420

421421
/**
422422
* @param \Symfony\Component\EventDispatcher\GenericEvent $event
423423
*/
424-
public static function getSettings(GenericEvent $event)
425-
{
426-
/**
427-
* @var \MyAdmin\Settings $settings
428-
**/
429-
$settings = $event->getSubject();
430-
$settings->setTarget('module');
424+
public static function getSettings(GenericEvent $event)
425+
{
426+
/**
427+
* @var \MyAdmin\Settings $settings
428+
**/
429+
$settings = $event->getSubject();
430+
$settings->setTarget('module');
431431
$settings->add_select_master(_(self::$module), _('Default Servers'), self::$module, 'new_website_plesk_server', _('Default Plesk Setup Server'), NEW_WEBSITE_PLESK_SERVER, get_service_define('WEB_PLESK'));
432432
$settings->add_dropdown_setting(self::$module, _('Out of Stock'), 'outofstock_webhosting_plesk', _('Out Of Stock Plesk Webhosting'), _('Enable/Disable Sales Of This Type'), $settings->get_setting('OUTOFSTOCK_WEBHOSTING_PLESK'), ['0', '1'], ['No', 'Yes']);
433-
$settings->setTarget('global');
433+
$settings->setTarget('global');
434434
}
435435
}

0 commit comments

Comments
 (0)