Make $vars and $secureRandom required.
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
This commit is contained in:
parent
27fdc6575d
commit
8ebd31d686
|
@ -159,7 +159,7 @@ class OC {
|
||||||
'SCRIPT_FILENAME' => $_SERVER['SCRIPT_FILENAME'],
|
'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();
|
$scriptName = $fakeRequest->getScriptName();
|
||||||
if (substr($scriptName, -1) == '/') {
|
if (substr($scriptName, -1) == '/') {
|
||||||
$scriptName .= 'index.php';
|
$scriptName .= 'index.php';
|
||||||
|
|
|
@ -136,8 +136,8 @@ class Request implements \ArrayAccess, \Countable, IRequest {
|
||||||
* @param string $stream
|
* @param string $stream
|
||||||
* @see http://www.php.net/manual/en/reserved.variables.php
|
* @see http://www.php.net/manual/en/reserved.variables.php
|
||||||
*/
|
*/
|
||||||
public function __construct(array $vars = [],
|
public function __construct(array $vars,
|
||||||
ISecureRandom $secureRandom = null,
|
ISecureRandom $secureRandom,
|
||||||
IConfig $config,
|
IConfig $config,
|
||||||
CsrfTokenManager $csrfTokenManager = null,
|
CsrfTokenManager $csrfTokenManager = null,
|
||||||
string $stream = 'php://input') {
|
string $stream = 'php://input') {
|
||||||
|
|
Loading…
Reference in New Issue