mirror of
https://github.com/iluvcapra/wavinfo.git
synced 2026-10-01 17:27:42 +00:00
Ruff: Fixed C408
This commit is contained in:
+1
-1
@@ -70,7 +70,7 @@ ignore = [
|
||||
'SIM115', # Use a context manager for opening files
|
||||
'UP031', #Use format specifiers instead of percent format
|
||||
'C408', # Unnecessary `dict()` call (rewrite as a literal)
|
||||
'C417' # Unnecessary `map()` usage (rewrite using a generator expression)
|
||||
# 'C417' # Unnecessary `map()` usage (rewrite using a generator expression)
|
||||
]
|
||||
|
||||
# [tool.pylint]
|
||||
|
||||
@@ -207,6 +207,6 @@ class WavADMReader:
|
||||
return rd
|
||||
|
||||
return dict(
|
||||
channel_entries=list(map(lambda z: make_entry(z), self.channel_uids)),
|
||||
channel_entries=[make_entry(z) for z in self.channel_uids],
|
||||
programme=self.programme(),
|
||||
)
|
||||
|
||||
@@ -683,8 +683,8 @@ class WavDolbyMetadataReader:
|
||||
]
|
||||
|
||||
def to_dict(self) -> dict:
|
||||
ddp = map(lambda x: asdict(x), self.dolby_digital_plus())
|
||||
atmos = map(lambda x: asdict(x), self.dolby_atmos())
|
||||
ddp = [asdict(x) for x in self.dolby_digital_plus()]
|
||||
atmos = [asdict(x) for x in self.dolby_atmos()]
|
||||
# atmos_sup = map(lambda x: asdict(x), self.dolby_atmos_supplemental())
|
||||
|
||||
return dict(dolby_digital_plus=list(ddp), dolby_atmos=list(atmos))
|
||||
|
||||
Reference in New Issue
Block a user