MCPcopy Index your code
hub / github.com/coder/coder / activate

Function activate

site/src/api/queries/workspaces.ts:405–417  ·  view source on GitHub ↗
(workspace: Workspace, queryClient: QueryClient)

Source from the content-addressed store, hash-verified

403};
404
405export const activate = (workspace: Workspace, queryClient: QueryClient) => {
406 return {
407 mutationFn: () => {
408 return API.updateWorkspaceDormancy(workspace.id, false);
409 },
410 onSuccess: (updatedWorkspace: Workspace) => {
411 queryClient.setQueryData(
412 workspaceByOwnerAndNameKey(workspace.owner_name, workspace.name),
413 updatedWorkspace,
414 );
415 },
416 };
417};
418
419const updateWorkspaceBuild = async (
420 build: WorkspaceBuild,

Callers 1

WorkspaceReadyPageFunction · 0.90

Calls 1

Tested by

no test coverage detected