Skip to content

Commit

Permalink
walrus operator was swallowing stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
z80dev committed Oct 24, 2023
1 parent 64e29e9 commit 8df6803
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ape_vyper/compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -402,10 +402,10 @@ def get_optimization_pragma_map(
base_path = base_path or self.config_manager.contracts_folder
optimization_pragma_map: Dict[Union[str, bool], Set[Path]] = {}
for path in contract_filepaths:
if pragma := get_optimization_pragma(path):
if pragma not in optimization_pragma_map:
optimization_pragma_map[pragma] = set()
optimization_pragma_map[pragma].add(path)
pragma = get_optimization_pragma(path) or True
if pragma not in optimization_pragma_map:
optimization_pragma_map[pragma] = set()
optimization_pragma_map[pragma].add(path)

return optimization_pragma_map

Expand Down

0 comments on commit 8df6803

Please sign in to comment.