Return types

This commit is contained in:
2024-07-22 02:36:28 +02:00
parent af588ab174
commit 2168e37413
12 changed files with 35 additions and 46 deletions
+4 -6
View File
@@ -6,24 +6,22 @@ use Khofmann\Request\Request;
class Input
{
public static function post($index, $defaultValue = null)
public static function post(string $index, $defaultValue = null)
{
return Request::request()->getInputHandler()->post($index, $defaultValue);
}
public static function patch($index, $defaultValue = null)
public static function patch(string $index, $defaultValue = null)
{
return Request::request()->getInputHandler()->post($index, $defaultValue);
}
public static function get($index, $defaultValue = null)
public static function get(string $index, $defaultValue = null)
{
return Request::request()->getInputHandler()->get($index, $defaultValue);
}
public static function file($index, $defaultValue = null)
public static function file(string $index, $defaultValue = null)
{
return Request::request()->getInputHandler()->file($index, $defaultValue);
}