Added a fix to avoid becoming one's own neighbour.

This commit is contained in:
Eichhornchen
2021-01-06 22:04:23 +01:00
parent ab554bb3fe
commit 15917bfb32
2 changed files with 6 additions and 1 deletions

View File

@ -176,6 +176,9 @@ class HelloTLV(TLV):
f"the id {self.source_id}.")
sender.id = self.source_id
if self.source_id == user.id:
sender.marked_as_banned = True
if not sender.active:
sender.id = self.source_id # The sender we are given misses an id
time_hl = time.time()