Commit 347f62e1 authored by Agrigor's avatar Agrigor

msg in communication class is now a local variable

parent d36920e0
......@@ -44,9 +44,9 @@ class Communication:
buzzer.register_observer(self)
def notify(self, buzzer):
self.__msg = "Button " + str(buzzer.number) + " pressed"
self.send(self.msg)
print(self.msg + " -> " + self.__target_ip)
msg = "Button " + str(buzzer.number) + " pressed"
self.send(msg)
print(msg + " -> " + self.__target_ip)
class Buzzer:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment