Revision 0325be55 snf-pithos-app/pithos/api/util.py
b/snf-pithos-app/pithos/api/util.py | ||
---|---|---|
281 | 281 |
meta['checksum'] = md5.hexdigest().lower() |
282 | 282 |
|
283 | 283 |
def is_uuid(str): |
284 |
if str is None: |
|
285 |
return False |
|
284 | 286 |
try: |
285 | 287 |
uuid.UUID(str) |
286 | 288 |
except ValueError: |
287 |
return False |
|
289 |
return False
|
|
288 | 290 |
else: |
289 | 291 |
return True |
290 | 292 |
|
Also available in: Unified diff