summaryrefslogtreecommitdiff
path: root/client/src/leap/soledad/client/_secrets/util.py
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/leap/soledad/client/_secrets/util.py')
-rw-r--r--client/src/leap/soledad/client/_secrets/util.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/client/src/leap/soledad/client/_secrets/util.py b/client/src/leap/soledad/client/_secrets/util.py
index 75418518..6401889b 100644
--- a/client/src/leap/soledad/client/_secrets/util.py
+++ b/client/src/leap/soledad/client/_secrets/util.py
@@ -23,12 +23,20 @@ class SecretsError(Exception):
pass
-class EmitMixin(object):
+class UserDataMixin(object):
+ """
+ When emitting an event, we have to pass a dictionary containing user data.
+ This class only defines a property so we don't have to define it in
+ multiple places.
+ """
@property
def _user_data(self):
uuid = self._soledad.uuid
userid = self._soledad.userid
+ # TODO: seems that uuid and userid hold the same value! We should check
+ # whether we should pass something different or if the events api
+ # really needs two different values.
return {'uuid': uuid, 'userid': userid}