Skip to content

Commit

Permalink
fix end-of-line parsing error (#46)
Browse files Browse the repository at this point in the history
* fix: end-of-line parsing error
  • Loading branch information
idoavrah authored Dec 25, 2023
1 parent 0780b96 commit ba9f703
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "tftui"
version = "0.10.1"
version = "0.10.2"
description = "Terraform Textual User Interface"
authors = ["Ido Avraham"]
license = "Apache-2.0"
Expand Down
6 changes: 3 additions & 3 deletions tftui/state.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,13 @@ async def refresh_state(self) -> None:
if line.startswith("#"):
(fullname, name, submodule, type, is_tainted) = State.parse_block(line)
contents = ""
elif line == "}":
contents += line + "\n"
elif line.startswith("}"):
contents += line.rstrip() + "\n"
block = Block(submodule, name, type, is_tainted)
block.contents = contents
self.state_tree[fullname] = block
else:
contents += line + "\n"
contents += line.rstrip() + "\n"


if __name__ == "__main__":
Expand Down

0 comments on commit ba9f703

Please sign in to comment.