yogeshkk / K8sPurger

Hunt Unused Resources In Kubernetes
Apache License 2.0
254 stars 27 forks source link

Replace with list comprehension #18

Closed gregwhorley closed 2 years ago

gregwhorley commented 2 years ago

https://github.com/yogeshkk/K8sPurger/blob/f91e1d7d8da2f56078529e756223ee4738a5fe51/K8sPurger.py#L77-L82

Could be:

def Diffrance(listA, listB):
    return [i for i in listA if i not in listB]
yogeshkk commented 2 years ago

@gregwhorley look like it can work but I don't have access to my PC for atleast a week. Can you test and raise MR. Will happy to merge.

gregwhorley commented 2 years ago

https://github.com/yogeshkk/K8sPurger/pull/19

yogeshkk commented 2 years ago

Thanks for contribution. MR is merged so closing the issue