fixing door logic
authorMark Tearle <mtearle@ucc.gu.uwa.edu.au>
Sun, 12 Dec 2004 06:35:26 +0000 (06:35 +0000)
committerMark Tearle <mtearle@ucc.gu.uwa.edu.au>
Sun, 12 Dec 2004 06:35:26 +0000 (06:35 +0000)
sql-edition/servers/VendingMachine.py

index d7e7a8f..709b90f 100644 (file)
@@ -88,9 +88,9 @@ class VendingMachine:
 
        def handle_event(self, code, text):
                if code == '400':
-                       self.events.append((DOOR, 0))
-               elif code == '401':
                        self.events.append((DOOR, 1))
+               elif code == '401':
+                       self.events.append((DOOR, 0))
                elif code == '610':
                        self.events.append((SWITCH, None))
                        self.interpret_switches(text)

UCC git Repository :: git.ucc.asn.au