Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/sugar/util.py
diff options
context:
space:
mode:
authorDan Williams <dcbw@redhat.com>2006-06-22 18:05:38 (GMT)
committer Dan Williams <dcbw@redhat.com>2006-06-22 18:05:38 (GMT)
commit2840af85ce3b7d998a356f5606ce0d6637b4092e (patch)
treef35d676ff661e393625f872b284e9cc20e9bd750 /sugar/util.py
parent2351ee045885dec490c8937d9e60d242d4af4ce7 (diff)
Stop abusing ZeroConf by overloading the service type field; overload the service name field instead like everyone else does
Diffstat (limited to 'sugar/util.py')
-rw-r--r--sugar/util.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/sugar/util.py b/sugar/util.py
index 4f83751..bfddf32 100644
--- a/sugar/util.py
+++ b/sugar/util.py
@@ -22,18 +22,18 @@ def unique_id(data = ''):
return _stringify_sha(_sha_data(data_string))
-ACTIVITY_UID_LEN = 40
+ACTIVITY_ID_LEN = 40
def is_hex(s):
return s.strip(string.hexdigits) == ''
-def validate_activity_uid(uid):
- """Validate an activity UID."""
- if type(uid) != type("") and type(uid) != type(u""):
+def validate_activity_id(actid):
+ """Validate an activity ID."""
+ if type(actid) != type("") and type(actid) != type(u""):
return False
- if len(uid) != ACTIVITY_UID_LEN:
+ if len(actid) != ACTIVITY_ID_LEN:
return False
- if not is_hex(uid):
+ if not is_hex(actid):
return False
return True