Added exception for null kubectl commands

This commit is contained in:
Shivam Gupta
2020-01-17 10:15:28 +05:30
parent fdacb8e073
commit e7d77ef817
4 changed files with 9 additions and 4 deletions
+2
View File
@@ -80,6 +80,8 @@ export class Kubectl {
}
public executeCommand(customCommand: string, args?: string) {
if(!customCommand)
throw new Error('NullCommandForKubectl');
return args ? this.execute([customCommand, args]) : this.execute([customCommand]);
}