Skip to content

Commit 73bd919

Browse files
authored
Resolves: MTV-3618 | can't upload vddk tarball from private namespace (#2086)
Signed-off-by: Aviv Turgeman <[email protected]>
1 parent e8ae6c3 commit 73bd919

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/components/VddkUploader/hooks/useVddkBuildImage.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,11 @@
1-
import { useActiveNamespace, useK8sWatchResource } from '@openshift-console/dynamic-plugin-sdk';
2-
import { Namespace } from '@utils/constants';
1+
import { useK8sWatchResource } from '@openshift-console/dynamic-plugin-sdk';
32
import { isEmpty } from '@utils/helpers';
43
import { getDefaultNamespace } from '@utils/namespaces';
54

65
import type { VddkBuild } from '../utils/types';
76
import { getVddkImageBuildResponse } from '../utils/utils';
87

98
export const useVddkBuildImage = (buildName: string) => {
10-
const [activeNamespace] = useActiveNamespace();
11-
const namespace =
12-
activeNamespace === Namespace.AllProjects ? getDefaultNamespace() : activeNamespace;
13-
149
const [vddkBuild] = useK8sWatchResource<VddkBuild>(
1510
buildName
1611
? {
@@ -20,7 +15,7 @@ export const useVddkBuildImage = (buildName: string) => {
2015
version: 'v1',
2116
},
2217
name: buildName,
23-
namespace,
18+
namespace: getDefaultNamespace(),
2419
}
2520
: null,
2621
);

0 commit comments

Comments
 (0)