1
0
Fork 0
mirror of synced 2024-06-18 18:34:51 +12:00

fix binary hash func when binary is missing

This commit is contained in:
Nick Sweeting 2020-07-27 18:51:29 -04:00
parent cdb1485150
commit 904f728785

View file

@ -492,6 +492,8 @@ def bin_path(binary: Optional[str]) -> Optional[str]:
return shutil.which(os.path.expanduser(binary)) or binary
def bin_hash(binary: Optional[str]) -> Optional[str]:
if binary is None:
return None
abs_path = bin_path(binary)
if abs_path is None:
return None