mirror of
https://github.com/nextcloud/server.git
synced 2024-08-13 02:10:44 +02:00
Fixed dirInfo check for non existing dir in files ajax call
This commit is contained in:
parent
2b8bb01211
commit
7c9537f33a
@ -7,7 +7,7 @@ OCP\JSON::checkLoggedIn();
|
||||
$dir = isset( $_GET['dir'] ) ? $_GET['dir'] : '';
|
||||
$dir = \OC\Files\Filesystem::normalizePath($dir);
|
||||
$dirInfo = \OC\Files\Filesystem::getFileInfo($dir);
|
||||
if (!$dirInfo->getType() === 'dir') {
|
||||
if (!$dirInfo || !$dirInfo->getType() === 'dir') {
|
||||
header("HTTP/1.0 404 Not Found");
|
||||
exit();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user