[locationline] Do not show empty (aka root) paths
Searchbox activity can send requests to the location line breadcrumb to display a root "/" path, when the current directory entry is a Recents, a Fake entry, a mounted Zip file viz., all special directories that are rooted according to the directory model API directoryModel.getCurrentDirEntry(); However, root paths have no path components and cause the location line show() code to throw an exception accessing components[0].name, causing files app to become totally unresponsive to user input. Change location line to ignore requests to show a root (empty) path and no JS exceptions is the result. Bug: 1107391 Change-Id: I74523e94ec29f65342b393c2b176f8f4771e838d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2308613Reviewed-by:Alex Danilo <adanilo@chromium.org> Commit-Queue: Noel Gordon <noel@chromium.org> Cr-Commit-Position: refs/heads/master@{#790271}
Showing
Please register or sign in to comment