diff options
author | Christoph Wurst <ChristophWurst@users.noreply.github.com> | 2020-12-16 12:43:06 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-16 12:43:06 +0100 |
commit | 820f9f4f63d093536547a3ee7f3f8a50d83aeff4 (patch) | |
tree | 0dcd1aa409d67db8c78116f25b7beaded460809b /lib | |
parent | d613450e4ed44f976a2f6d3fea7115a6a80d6122 (diff) | |
parent | 9558734d07a85dc4b206e8d541403f32cf58db64 (diff) | |
download | nextcloud-server-820f9f4f63d093536547a3ee7f3f8a50d83aeff4.tar.gz nextcloud-server-820f9f4f63d093536547a3ee7f3f8a50d83aeff4.zip |
Merge pull request #24629 from nextcloud/enh/noid/optional-before-required
Make $vars and $secureRandom required.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/base.php | 2 | ||||
-rw-r--r-- | lib/private/AppFramework/Http/Request.php | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/base.php b/lib/base.php index 115a0968af2..3e89cbe6c54 100644 --- a/lib/base.php +++ b/lib/base.php @@ -159,7 +159,7 @@ class OC { 'SCRIPT_FILENAME' => $_SERVER['SCRIPT_FILENAME'], ], ]; - $fakeRequest = new \OC\AppFramework\Http\Request($params, null, new \OC\AllConfig(new \OC\SystemConfig(self::$config))); + $fakeRequest = new \OC\AppFramework\Http\Request($params, new \OC\Security\SecureRandom(), new \OC\AllConfig(new \OC\SystemConfig(self::$config))); $scriptName = $fakeRequest->getScriptName(); if (substr($scriptName, -1) == '/') { $scriptName .= 'index.php'; diff --git a/lib/private/AppFramework/Http/Request.php b/lib/private/AppFramework/Http/Request.php index 3705ab2e92d..a873ee96772 100644 --- a/lib/private/AppFramework/Http/Request.php +++ b/lib/private/AppFramework/Http/Request.php @@ -136,8 +136,8 @@ class Request implements \ArrayAccess, \Countable, IRequest { * @param string $stream * @see http://www.php.net/manual/en/reserved.variables.php */ - public function __construct(array $vars = [], - ISecureRandom $secureRandom = null, + public function __construct(array $vars, + ISecureRandom $secureRandom, IConfig $config, CsrfTokenManager $csrfTokenManager = null, string $stream = 'php://input') { |