Finalize ZMQ interface
This commit is contained in:
parent
cedac41b10
commit
feb280ed8c
2 changed files with 2 additions and 2 deletions
|
@ -397,7 +397,7 @@ def rss(token, onstart=False):
|
|||
def mail(to_email, subject, message):
|
||||
|
||||
zmsg = {
|
||||
'topic': 'email:sendmail',
|
||||
'topic': 'email:send',
|
||||
'to': to_email,
|
||||
'subject': subject,
|
||||
'content': message
|
||||
|
|
|
@ -15,7 +15,7 @@ context = zmq.Context()
|
|||
|
||||
def process(message):
|
||||
data = json.loads(message)
|
||||
if data['topic'] == 'email:newmail':
|
||||
if data['topic'] == 'email:mail':
|
||||
logger.info('newmail => {}'.format(data))
|
||||
processor.enqueue({'request': 'new_mail', 'data': data})
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue