--- a/iro/model/message.py Fri Mar 23 16:21:22 2012 +0100
+++ b/iro/model/message.py Fri Mar 23 16:22:32 2012 +0100
@@ -21,16 +21,12 @@
class SMS(Message):
def __init__(self, cont, from_ = None):
- Message.__init__(self, cont, typ="sms")
+ Message.__init__(self, cont.encode("utf-8"), typ="sms")
self.from_ = from_
- def sendto(self,anbieter,recipients):
- anbieter.sendSMS(self,recipients)
-
-
class Fax(Message):
def __init__(self,header,cont,attachments=[]):
- Message.__init__(self,cont, typ="fax")
+ Message.__init__(self,cont.encode("utf-8"),typ="fax")
self.header=header
self.attachments=attachments
--- a/iro/offer/smstrade.py Fri Mar 23 16:21:22 2012 +0100
+++ b/iro/offer/smstrade.py Fri Mar 23 16:22:32 2012 +0100
@@ -112,7 +112,7 @@
parameters= {"key": self.key,
"route": route,
"to": to,
- "message": sms.content.encode("utf-8"),
+ "message": sms.content,
"charset":"utf-8",
"debug": self.testmode,
"message_id":True,
@@ -127,7 +127,7 @@
length=len(sms.content)
for s in doubleChar:
- length += sms.content.encode("utf-8").count(s)
+ length += sms.content.count(s)
parameters["concat_sms"] = True if length > 160 else False
ps={}