minor bugfixes

This commit is contained in:
Stephan Richter
2020-11-13 11:55:59 +01:00
parent 9eb8f5443a
commit f2ee754064
7 changed files with 15 additions and 12 deletions

View File

@@ -47,8 +47,9 @@ public class Contact extends Tile{
}
public Contact addr(int address) {
contactsByAddr.remove(addr); // alte ID aus der Map löschen
addr = address;
contactsByAddr.put(addr, this);
if (addr != 0) contactsByAddr.put(addr, this); // neue ID setzen
return this;
}