Skip to content

Commit

Permalink
refactor: last_item renamed to last_block in ConfigUpdater
Browse files Browse the repository at this point in the history
  • Loading branch information
andreoliwa committed Feb 28, 2021
1 parent e54c638 commit 2f6efd1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/nitpick/plugins/setup_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,8 @@ def get_missing_output(self) -> str:
for section in sorted(missing):
expected_config: Dict = self.expected_config[section]
if self.apply:
if self.updater.last_item:
self.updater.last_item.add_after.space(1)
if self.updater.last_block:
self.updater.last_block.add_after.space(1)
self.updater.add_section(section)
self.updater[section].update(expected_config)
parser[section] = expected_config
Expand Down

0 comments on commit 2f6efd1

Please sign in to comment.