Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions apps/files/src/actions/sidebarAction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ export const action = new FileAction({
async exec(node: Node, view: View, dir: string) {
try {
// If the sidebar is already open for the current file, do nothing
if (window.OCA.Files.Sidebar.file === node.path) {
if (window.OCA.Files?.Sidebar?.file === node.path) {
logger.debug('Sidebar already open for this file', { node })
return null
}
// Open sidebar and set active tab to sharing by default
window.OCA.Files.Sidebar.setActiveTab('sharing')
window.OCA.Files?.Sidebar?.setActiveTab('sharing')

// TODO: migrate Sidebar to use a Node instead
await window.OCA.Files.Sidebar.open(node.path)
await window.OCA.Files?.Sidebar?.open(node.path)

// Silently update current fileid
window.OCP?.Files?.Router?.goToRoute(
Expand Down
4 changes: 2 additions & 2 deletions dist/files-init.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/files-init.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/files-main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/files-main.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/files_sharing-init.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/files_sharing-init.js.map

Large diffs are not rendered by default.

Loading