Skip to content

Commit

Permalink
fixup! CHE-2919 improve process panel
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleksii Orel committed Dec 6, 2016
1 parent e59465b commit 676b2c0
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,7 @@ export class NavbarRecentWorkspacesController {
if (recentWorkspaces.length > MAX_RECENT_WORKSPACES_ITEMS) {
let pos: number = veryRecentWorkspace ? recentWorkspaces.indexOf(veryRecentWorkspace) : -1;
if (veryRecentWorkspace && pos >= MAX_RECENT_WORKSPACES_ITEMS) {
recentWorkspaces = recentWorkspaces.slice(0, MAX_RECENT_WORKSPACES_ITEMS - 1);
recentWorkspaces.push(veryRecentWorkspace);
recentWorkspaces.splice(MAX_RECENT_WORKSPACES_ITEMS - 1, recentWorkspaces.length , veryRecentWorkspace);
} else {
recentWorkspaces = recentWorkspaces.slice(0, MAX_RECENT_WORKSPACES_ITEMS);
}
Expand Down Expand Up @@ -180,7 +179,7 @@ export class NavbarRecentWorkspacesController {
* @returns {boolean}
*/
isOpen(workspaceId: string): boolean {
return this.ideSvc && this.ideSvc.openedWorkspace && this.ideSvc.openedWorkspace.id === workspaceId;
return this.ideSvc.openedWorkspace && this.ideSvc.openedWorkspace.id === workspaceId;
}

/**
Expand Down

0 comments on commit 676b2c0

Please sign in to comment.