Skip to content

Commit

Permalink
[Plugin API] Fix Theia workspace name getter if no folders are opened
Browse files Browse the repository at this point in the history
Signed-off-by: Mykola Morhun <[email protected]>
  • Loading branch information
mmorhun authored and akosyakov committed Jul 3, 2019
1 parent 8b3cdca commit d4c631c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/plugin-ext/src/plugin/workspace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export class WorkspaceExtImpl implements WorkspaceExt {
}

get name(): string | undefined {
if (this.workspaceFolders) {
if (this.workspaceFolders && this.workspaceFolders.length > 0) {
return new Path(this.workspaceFolders[0].uri.path).base;
}

Expand Down

0 comments on commit d4c631c

Please sign in to comment.