Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(927)

Unified Diff: ui/file_manager/file_manager/foreground/js/ui/directory_tree.js

Issue 940443003: Files.app: Skip updating subdirectories of a volume whose display root is not gotten yet. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/file_manager/file_manager/foreground/js/ui/directory_tree.js
diff --git a/ui/file_manager/file_manager/foreground/js/ui/directory_tree.js b/ui/file_manager/file_manager/foreground/js/ui/directory_tree.js
index 724c1621077809e6066e0e481a1ddb4c94fbb00d..ca9be48c43b4b3d84c3e424100f9234034a40404 100644
--- a/ui/file_manager/file_manager/foreground/js/ui/directory_tree.js
+++ b/ui/file_manager/file_manager/foreground/js/ui/directory_tree.js
@@ -223,7 +223,7 @@ DirectoryItem.prototype.handleClick = function(e) {
*/
DirectoryItem.prototype.updateSubDirectories = function(
recursive, opt_successCallback, opt_errorCallback) {
- if (util.isFakeEntry(this.entry)) {
+ if (!this.entry || util.isFakeEntry(this.entry)) {
if (opt_errorCallback)
opt_errorCallback();
return;
@@ -445,6 +445,11 @@ function VolumeItem(modelItem, tree) {
VolumeItem.prototype = {
__proto__: DirectoryItem.prototype,
+ /**
+ * Directory entry for the display root, whose initial value is null.
+ * @type {DirectoryEntry}
+ * @override
+ */
get entry() {
return this.volumeInfo_.displayRoot;
},

Powered by Google App Engine
This is Rietveld 408576698