|
@@ -437,12 +437,14 @@ class WXBot:
|
|
elif mtype == 3:
|
|
elif mtype == 3:
|
|
msg_content['type'] = 3
|
|
msg_content['type'] = 3
|
|
msg_content['data'] = self.get_msg_img_url(msg_id)
|
|
msg_content['data'] = self.get_msg_img_url(msg_id)
|
|
|
|
+ msg_content['img']=self.session.get(msg_content['data']).content.encode('hex')
|
|
if self.DEBUG:
|
|
if self.DEBUG:
|
|
image = self.get_msg_img(msg_id)
|
|
image = self.get_msg_img(msg_id)
|
|
print ' %s[Image] %s' % (msg_prefix, image)
|
|
print ' %s[Image] %s' % (msg_prefix, image)
|
|
elif mtype == 34:
|
|
elif mtype == 34:
|
|
msg_content['type'] = 4
|
|
msg_content['type'] = 4
|
|
msg_content['data'] = self.get_voice_url(msg_id)
|
|
msg_content['data'] = self.get_voice_url(msg_id)
|
|
|
|
+ msg_content['voice'] = self.session.get(msg_content['data']).content.encode('hex')
|
|
if self.DEBUG:
|
|
if self.DEBUG:
|
|
voice = self.get_voice(msg_id)
|
|
voice = self.get_voice(msg_id)
|
|
print ' %s[Voice] %s' % (msg_prefix, voice)
|
|
print ' %s[Voice] %s' % (msg_prefix, voice)
|