From 6a242eb30f0e78faef2a39a3dde7e1caa0b53a35 Mon Sep 17 00:00:00 2001 From: Romain Bignon Date: Wed, 17 Nov 2010 19:30:51 +0100 Subject: [PATCH] fix getting of url when filling contact --- weboob/backends/aum/backend.py | 3 ++- weboob/capabilities/contact.py | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/weboob/backends/aum/backend.py b/weboob/backends/aum/backend.py index 70e3331a..ddc72f4c 100644 --- a/weboob/backends/aum/backend.py +++ b/weboob/backends/aum/backend.py @@ -330,7 +330,8 @@ class AuMBackend(BaseBackend, ICapMessages, ICapMessagesPost, ICapDating, ICapCh contact.name = profile.get_name() contact.status = s else: - contact = Contact(_id, profile.get_name(), s, self.browser.id2url(_id)) + contact = Contact(_id, profile.get_name(), s) + contact.url = self.browser.id2url(_id) contact.status_msg = profile.get_status() contact.summary = profile.description for photo in profile.photos: diff --git a/weboob/capabilities/contact.py b/weboob/capabilities/contact.py index 740c8100..65eb45e6 100644 --- a/weboob/capabilities/contact.py +++ b/weboob/capabilities/contact.py @@ -59,11 +59,11 @@ class Contact(CapBaseObject): STATUS_OFFLINE = 0x004 STATUS_ALL = 0xfff - def __init__(self, id, name, status, url): + def __init__(self, id, name, status): CapBaseObject.__init__(self, id) self.add_field('name', basestring, name) self.add_field('status', int, status) - self.add_field('url', basestring, url) + self.add_field('url', basestring) self.add_field('status_msg', basestring) self.add_field('summary', basestring) self.add_field('photos', dict, OrderedDict())