diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2018-07-26 15:14:28 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2018-07-26 15:14:28 +0200 |
commit | 309ae6d9c0c1a0330d86803b231d004bb318ab6e (patch) | |
tree | f1e22a85537130df4e12f782106246e3032b033b /apps | |
parent | adcc061166ab86bd39b004bd85847320fdd2d525 (diff) | |
download | nextcloud-server-309ae6d9c0c1a0330d86803b231d004bb318ab6e.tar.gz nextcloud-server-309ae6d9c0c1a0330d86803b231d004bb318ab6e.zip |
Set the favorites to the empty array on failure
Else it will start throwing errors because null is not iteratable.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files/lib/Controller/ViewController.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files/lib/Controller/ViewController.php b/apps/files/lib/Controller/ViewController.php index 0a13af32331..0655718f8c1 100644 --- a/apps/files/lib/Controller/ViewController.php +++ b/apps/files/lib/Controller/ViewController.php @@ -162,7 +162,7 @@ class ViewController extends Controller { try { $favElements = $this->activityHelper->getFavoriteFilePaths($this->userSession->getUser()->getUID()); } catch (\RuntimeException $e) { - $favElements['folders'] = null; + $favElements['folders'] = []; } $collapseClasses = ''; |