]> source.dussan.org Git - nextcloud-server.git/commitdiff
make sure that all expected array keys are available
authorBjörn Schießle <schiessle@owncloud.com>
Tue, 4 Dec 2012 13:52:59 +0000 (14:52 +0100)
committerBjörn Schießle <schiessle@owncloud.com>
Thu, 6 Dec 2012 14:57:53 +0000 (15:57 +0100)
apps/files_sharing/public.php

index ac2473687384d792a1530a978f6e57783b007099..71c18380a3b31dc3a069abe28f72a27ad9626960 100644 (file)
@@ -233,7 +233,7 @@ if ($linkItem) {
                        $breadcrumb[] = array('dir' => '/', 'name' => basename($basePath));
 
                        //add subdir breadcrumbs
-                       foreach (explode('/', urldecode($_GET['path'])) as $i) {
+                       foreach (explode('/', urldecode($getPath)) as $i) {
                                if ($i != '') {
                                        $pathtohere .= '/'.$i;
                                        $breadcrumb[] = array('dir' => $pathtohere, 'name' => $i);
@@ -251,6 +251,7 @@ if ($linkItem) {
                        $folder = new OCP\Template('files', 'index', '');
                        $folder->assign('fileList', $list->fetchPage(), false);
                        $folder->assign('breadcrumb', $breadcrumbNav->fetchPage(), false);
+                       $folder->assign('dir', basename($dir));
                        $folder->assign('isCreatable', false);
                        $folder->assign('permissions', 0);
                        $folder->assign('files', $files);