mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
add workspace fixes
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
This commit is contained in:
parent
8a34184c46
commit
82f2724ddf
@ -6,6 +6,8 @@ import { commandRegistry } from "../../../extensions/registries/command-registry
|
||||
import { Input, InputValidator } from "../input";
|
||||
import { navigate } from "../../navigation";
|
||||
import { CommandOverlay } from "../command-palette/command-container";
|
||||
import { landingURL } from "../+landing-page";
|
||||
import { clusterStore } from "../../../common/cluster-store";
|
||||
|
||||
const uniqueWorkspaceName: InputValidator = {
|
||||
condition: ({ required }) => required,
|
||||
@ -24,8 +26,13 @@ export class AddWorkspace extends React.Component {
|
||||
name
|
||||
}));
|
||||
|
||||
if (!workspace) {
|
||||
return;
|
||||
}
|
||||
|
||||
workspaceStore.setActive(workspace.id);
|
||||
navigate("/");
|
||||
clusterStore.setActive(null);
|
||||
navigate(landingURL());
|
||||
CommandOverlay.close();
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user