code cleanup

This commit is contained in:
tracer 2022-01-22 17:08:05 +01:00
parent 3363414aa0
commit 108bafe299
1 changed files with 2 additions and 4 deletions

View File

@ -1,16 +1,14 @@
#!/usr/bin/keyhelp-php81 #!/usr/bin/keyhelp-php81
<?php <?php
if (php_sapi_name() !== 'cli') { if (php_sapi_name() !== 'cli') {
exit; exit;
} }
require dirname(__DIR__) . '/vendor/autoload.php'; require dirname(path: __DIR__) . '/vendor/autoload.php';
use App\Controller\BindAPI; use App\Controller\BindAPI;
// read config $configFile = dirname(path: __DIR__) ."/config.json";
$configFile = __DIR__ ."/../config.json";
$configJSON = file_get_contents($configFile); $configJSON = file_get_contents($configFile);
$config = json_decode($configJSON, associative: true); $config = json_decode($configJSON, associative: true);