Commit 31e3145c authored by Tomáš Pospíšil's avatar Tomáš Pospíšil
Browse files

remove filter_inputs

parent b1f2bbf7
......@@ -120,7 +120,11 @@ final class Dumper
public static function getDirectory(): string
{
if (self::$rootDir === null) {
$scriptPath = filter_input(INPUT_SERVER, 'SCRIPT_FILENAME');
$scriptPath = $_SERVER['SCRIPT_FILENAME'] ?? null;
if ($scriptPath === null) {
return '';
}
$dir = realpath(dirname($scriptPath));
while (false !== $dir && !is_dir($dir . '/vendor')) {
......
......@@ -25,7 +25,7 @@ final class PersistentValue
session_start();
}
$get = filter_input(INPUT_POST, $settingCode, FILTER_SANITIZE_STRING);
$get = strip_tags($_POST[$settingCode]);
$fromSession = $_SESSION[self::PREFIX . $settingCode] ?? null;
if ($get === null && $fromSession === null) {
......
......@@ -63,7 +63,7 @@ final class WebSwitcherUrls
private function currentUrl(): string
{
$protocol = 'http';
if (filter_input(INPUT_SERVER, 'HTTPS')) {
if ($_SERVER['HTTPS'] ?? null) {
$protocol .= 's';
}
$httpHost = $_SERVER['HTTP_HOST'] ?? '';
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment