Skip to content

Commit

Permalink
Don't fail if the unit is already missing (#243)
Browse files Browse the repository at this point in the history
  • Loading branch information
dragomirp authored Oct 10, 2023
1 parent 0410d95 commit 77ad2cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/charm.py
Original file line number Diff line number Diff line change
Expand Up @@ -566,7 +566,7 @@ def _reconfigure_cluster(self, event: HookEvent):
"""
if (
hasattr(event, "unit")
and event.unit is not None
and event.relation.data.get(event.unit) is not None
and event.relation.data[event.unit].get("ip-to-remove") is not None
):
ip_to_remove = event.relation.data[event.unit].get("ip-to-remove")
Expand Down

0 comments on commit 77ad2cd

Please sign in to comment.