Skip to content

Commit 6d224f3

Browse files
committed
updates migrating off global tf handler to the MyAdminApp class handler
1 parent cee80df commit 6d224f3

7 files changed

Lines changed: 19 additions & 19 deletions

bin/parallels.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
<?php
33

44
require_once __DIR__.'/../../../../include/functions.inc.php';
5-
//$GLOBALS['tf']->session->create(160308,'services');
6-
//$GLOBALS['tf']->session->verify();
5+
//\MyAdmin\App::session()->create(160308,'services');
6+
//\MyAdmin\App::session()->verify();
77

88
$key = 'PLSK.03117920.0000';
99
$ipAddress = '206.72.205.242';
@@ -15,4 +15,4 @@
1515
//print_r($ka->retrieveKey($key));
1616

1717

18-
//$GLOBALS['tf']->session->destroy();
18+
//\MyAdmin\App::session()->destroy();

bin/parallels_getAvailableKeyTypesAndFeatures.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
<?php
33

44
require_once __DIR__.'/../../../../include/functions.inc.php';
5-
//$GLOBALS['tf']->session->create(160308,'services');
6-
//$GLOBALS['tf']->session->verify();
5+
//\MyAdmin\App::session()->create(160308,'services');
6+
//\MyAdmin\App::session()->verify();
77

88
$ka = new \Detain\Parallels\Parallels();
99
print_r($ka->getAvailableKeyTypesAndFeatures());
1010

11-
//$GLOBALS['tf']->session->destroy();
11+
//\MyAdmin\App::session()->destroy();

bin/parallels_getAvailableUpgrades.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
<?php
33

44
require_once __DIR__.'/../../../../include/functions.inc.php';
5-
//$GLOBALS['tf']->session->create(160308,'services');
6-
//$GLOBALS['tf']->session->verify();
5+
//\MyAdmin\App::session()->create(160308,'services');
6+
//\MyAdmin\App::session()->verify();
77

88
$key = 'PLSK.03117920.0000';
99
$ipAddress = '206.72.205.242';
1010
$ka = new \Detain\Parallels\Parallels();
1111
print_r($ka->getAvailableUpgrades($key));
1212

13-
//$GLOBALS['tf']->session->destroy();
13+
//\MyAdmin\App::session()->destroy();

bin/parallels_getKeyInfo.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
<?php
33

44
require_once __DIR__.'/../../../../include/functions.inc.php';
5-
//$GLOBALS['tf']->session->create(160308,'services');
6-
//$GLOBALS['tf']->session->verify();
5+
//\MyAdmin\App::session()->create(160308,'services');
6+
//\MyAdmin\App::session()->verify();
77

88
$key = $_SERVER['argv'][1];
99
$ipAddress = '206.72.205.242';
1010
$ka = new \Detain\Parallels\Parallels();
1111
print_r($ka->getKeyInfo($key));
1212

13-
//$GLOBALS['tf']->session->destroy();
13+
//\MyAdmin\App::session()->destroy();

bin/parallels_getKeyNumbers.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
<?php
33

44
require_once __DIR__.'/../../../../include/functions.inc.php';
5-
//$GLOBALS['tf']->session->create(160308,'services');
6-
//$GLOBALS['tf']->session->verify();
5+
//\MyAdmin\App::session()->create(160308,'services');
6+
//\MyAdmin\App::session()->verify();
77

88
$key = 'PLSK.03117920.0000';
99
$ipAddress = '206.72.205.242';
1010
$ka = new \Detain\Parallels\Parallels();
1111
print_r($ka->getKeyNumbers([$ipAddress]));
1212

13-
//$GLOBALS['tf']->session->destroy();
13+
//\MyAdmin\App::session()->destroy();

bin/parallels_retrieveKey.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
<?php
33

44
require_once __DIR__.'/../../../../include/functions.inc.php';
5-
//$GLOBALS['tf']->session->create(160308,'services');
6-
//$GLOBALS['tf']->session->verify();
5+
//\MyAdmin\App::session()->create(160308,'services');
6+
//\MyAdmin\App::session()->verify();
77

88
$key = 'PLSK.03117920.0000';
99
$ipAddress = '206.72.205.242';
1010
$ka = new \Detain\Parallels\Parallels();
1111
print_r($ka->retrieveKey($key));
1212

1313

14-
//$GLOBALS['tf']->session->destroy();
14+
//\MyAdmin\App::session()->destroy();

src/Plugin.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ public static function getChangeIp(GenericEvent $event)
109109
$event['status'] = 'error';
110110
$event['status_text'] = 'Error Code '.$result['faultcode'].': '.$result['fault'];
111111
} else {
112-
$GLOBALS['tf']->history->add($settings['TABLE'], 'change_ip', $event['newip'], $serviceClass->getId(), $serviceClass->getCustid());
112+
\MyAdmin\App::history()->add($settings['TABLE'], 'change_ip', $event['newip'], $serviceClass->getId(), $serviceClass->getCustid());
113113
$serviceClass->set_ip($event['newip'])->save();
114114
$event['status'] = 'ok';
115115
$event['status_text'] = 'The IP Address has been changed.';

0 commit comments

Comments
 (0)