Skip to content
This repository has been archived by the owner on Apr 3, 2020. It is now read-only.

Commit

Permalink
Files.app: Fix js exceptions in table rendering.
Browse files Browse the repository at this point in the history
The status column isn't always visible.  Account for that when attempting to update table elements.

BUG=461723

Review URL: https://codereview.chromium.org/952893008

Cr-Commit-Position: refs/heads/master@{#318060}
  • Loading branch information
kenobi authored and Commit bot committed Feb 25, 2015
1 parent 85b90ad commit 4e9ddaa
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions ui/file_manager/file_manager/foreground/js/ui/file_table.js
Original file line number Diff line number Diff line change
Expand Up @@ -742,8 +742,13 @@ FileTable.prototype.updateFileMetadata = function(item, entry) {
/** @type {!HTMLDivElement} */ (item.querySelector('.date')), entry);
this.updateSize_(
/** @type {!HTMLDivElement} */ (item.querySelector('.size')), entry);
this.updateStatus_(
/** @type {!HTMLDivElement} */ (item.querySelector('.status')), entry);

// The status column isn't always visible.
// TODO(kenobi): Clean up once the status column's fate is determined.
var statusEl = item.querySelector('.status');
if (statusEl) {
this.updateStatus_(/** @type {!HTMLDivElement} */ (statusEl), entry);
}
};

/**
Expand Down

0 comments on commit 4e9ddaa

Please sign in to comment.