diff options
Diffstat (limited to 'lib/thandy/keys.py')
-rw-r--r-- | lib/thandy/keys.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/thandy/keys.py b/lib/thandy/keys.py index 5442b26..a243fa7 100644 --- a/lib/thandy/keys.py +++ b/lib/thandy/keys.py @@ -47,7 +47,8 @@ class PublicKey: paths. """ assert role in thandy.formats.ALL_ROLES - self._roles.append((role, path)) + if (role, path) not in self._roles: + self._roles.append((role, path)) def clearRoles(self): """Remove all roles from this key.""" del self._roles[:] |