minor fixes here and there

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2018-12-22 13:42:10 +01:00
parent 13aa19e5f4
commit 3794003e63
8 changed files with 55 additions and 19 deletions

View File

@@ -36,7 +36,8 @@ require dirname(__DIR__) . '/vendor/autoload.php';
require dirname(__DIR__) . '/lib/tables.inc.php';
// include consts
require dirname(__DIR__) . '/lib/functions/logger/constant.logger.php';
require dirname(__DIR__) . '/lib/functions/constant.formfields.php';
require dirname(__DIR__) . '/lib/functions/constant.logger.php';
use Froxlor\Database\Database;
use Froxlor\Settings;

29
tests/linting.php Normal file
View File

@@ -0,0 +1,29 @@
<?php
require dirname(__DIR__) . '/vendor/autoload.php';
// Includes the Functions
require \Froxlor\Froxlor::getInstallDir() . '/lib/functions/constant.formfields.php';
require \Froxlor\Froxlor::getInstallDir() . '/lib/functions/constant.logger.php';
// Includes the MySQL-Tabledefinitions etc.
require \Froxlor\Froxlor::getInstallDir() . '/lib/tables.inc.php';
$functions = get_defined_functions();
$calls = array();
foreach ($functions['user'] as $func) {
// grep for function
exec('grep -ir "'.$func.'" '.dirname(__DIR__).'/lib/', $output);
exec('grep -ir "'.$func.'" '.dirname(__DIR__).'/install/', $output);
exec('grep -ir "'.$func.'" '.dirname(__DIR__).'/actions/', $output);
exec('grep -ir "'.$func.'" '.dirname(__DIR__).'/*.php', $output);
echo "***********************************************".PHP_EOL;
echo "******* ". $func." ************************".PHP_EOL;
echo "***********************************************".PHP_EOL;
foreach ($output as $file) {
echo str_replace(dirname(__DIR__), "", $file) . PHP_EOL;
}
echo PHP_EOL;
$output = array();
}