mirror of
https://github.com/Azure/k8s-set-context.git
synced 2026-06-25 08:19:27 +08:00
Vidya reddy pretty code (#53)
* updated action file with node16 * Code consistency using prettier and its workflow * Enforce Prettier * code fix * code fix * code fix Co-authored-by: Vidya Reddy <vidyareddy@microsoft.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
export enum Cluster {
|
||||
ARC = "arc",
|
||||
GENERIC = "generic",
|
||||
ARC = 'arc',
|
||||
GENERIC = 'generic'
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -9,8 +9,8 @@ export enum Cluster {
|
||||
* @returns The Cluster enum or undefined if it can't be parsed
|
||||
*/
|
||||
export const parseCluster = (str: string): Cluster | undefined =>
|
||||
Cluster[
|
||||
Object.keys(Cluster).filter(
|
||||
(k) => Cluster[k].toString().toLowerCase() === str.toLowerCase()
|
||||
)[0] as keyof typeof Cluster
|
||||
];
|
||||
Cluster[
|
||||
Object.keys(Cluster).filter(
|
||||
(k) => Cluster[k].toString().toLowerCase() === str.toLowerCase()
|
||||
)[0] as keyof typeof Cluster
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user