Add __hash__ for Country

This commit is contained in:
Konsta Vesterinen
2015-04-15 19:31:47 +03:00
parent f3cd912707
commit b2a53fd828

View File

@@ -85,6 +85,9 @@ class Country(object):
else:
return NotImplemented
def __hash__(self):
return hash(self.code)
def __ne__(self, other):
return not (self == other)