From 792c135e9aee821bf22640649228d3e5d035f568 Mon Sep 17 00:00:00 2001 From: Lucian Branescu Mihaila Date: Thu, 24 Jun 2010 11:52:15 +0000 Subject: Prototype implementation of downloadmanager. Fix initial load bug. Introduce many other bugs. Not tested enough. --- (limited to 'model.py') diff --git a/model.py b/model.py index 48e7bdb..38154c4 100644 --- a/model.py +++ b/model.py @@ -17,9 +17,9 @@ # import cjson -import sha import gobject import base64 +from hashlib import sha1 class Model(gobject.GObject): @@ -45,7 +45,7 @@ class Model(gobject.GObject): break self.data['shared_links'].insert(index, - {'hash':sha.new(str(url)).hexdigest(), + {'hash':sha1.new(str(url)).hexdigest(), 'url':str(url), 'title':str(title), 'thumb':base64.b64encode(thumb), 'owner':str(owner), -- cgit v0.9.1