Skip to content

Commit f464d62

Browse files
committed
fix: remove unnecessary None checks
1 parent 1327972 commit f464d62

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

beet/library/base.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -535,8 +535,6 @@ def list_files(
535535
extend = origin
536536

537537
for path, item in self.extra.items():
538-
if item is None:
539-
continue
540538
if extensions and not any(path.endswith(ext) for ext in extensions):
541539
continue
542540
if extend and not isinstance(item, extend):
@@ -1029,8 +1027,6 @@ def list_files(
10291027
extend = origin
10301028

10311029
for path, item in self.extra.items():
1032-
if item is None:
1033-
continue
10341030
if extensions and not any(path.endswith(ext) for ext in extensions):
10351031
continue
10361032
if extend and not isinstance(item, extend):
@@ -1163,7 +1159,7 @@ def unveil(self, prefix: str, origin: Union[FileSystemPath, UnveilMapping]):
11631159

11641160
def dump(self, origin: FileOrigin):
11651161
"""Write the content of the pack to a zipfile or to the filesystem"""
1166-
extra = {path: item for path, item in self.extra.items() if item is not None}
1162+
extra = {path: item for path, item in self.extra.items()}
11671163
_dump_files(origin, extra)
11681164

11691165
for namespace_name, namespace in self.items():

0 commit comments

Comments
 (0)