mirror of
https://github.com/pirate/ArchiveBox.git
synced 2025-08-28 16:50:01 +02:00
fix binary hash func when binary is missing
This commit is contained in:
@@ -492,6 +492,8 @@ def bin_path(binary: Optional[str]) -> Optional[str]:
|
|||||||
return shutil.which(os.path.expanduser(binary)) or binary
|
return shutil.which(os.path.expanduser(binary)) or binary
|
||||||
|
|
||||||
def bin_hash(binary: Optional[str]) -> Optional[str]:
|
def bin_hash(binary: Optional[str]) -> Optional[str]:
|
||||||
|
if binary is None:
|
||||||
|
return None
|
||||||
abs_path = bin_path(binary)
|
abs_path = bin_path(binary)
|
||||||
if abs_path is None:
|
if abs_path is None:
|
||||||
return None
|
return None
|
||||||
|
Reference in New Issue
Block a user