Commit 3ac0cb89 authored by Tijmen de Mes's avatar Tijmen de Mes

Set SIP URI earlier

parent 2428e5c6
...@@ -41,8 +41,8 @@ class OutgoingMessage(object): ...@@ -41,8 +41,8 @@ class OutgoingMessage(object):
self.content_type = content_type self.content_type = content_type
self.content = content self.content = content
self.id = id if id is not None else str(uuid.uuid4()) self.id = id if id is not None else str(uuid.uuid4())
self.timestamp = timestamp self.timestamp = timestamp if timestamp is not None else ISOTimestamp.now()
self.sip_uri = None self.sip_uri = SIPURI.parse('sip:%s' % self.uri)
@property @property
def message(self): def message(self):
...@@ -50,7 +50,6 @@ class OutgoingMessage(object): ...@@ -50,7 +50,6 @@ class OutgoingMessage(object):
def _lookup(self): def _lookup(self):
settings = SIPSimpleSettings() settings = SIPSimpleSettings()
self.sip_uri = SIPURI.parse('sip:%s' % self.uri)
if isinstance(self.account, Account): if isinstance(self.account, Account):
if self.account.sip.outbound_proxy is not None: if self.account.sip.outbound_proxy is not None:
proxy = self.account.sip.outbound_proxy proxy = self.account.sip.outbound_proxy
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment