Commit e0acbeec940683a4c6ecab5c357607b91d8963bf

Authored by Wesnydy Ribeiro
1 parent 82670e86

Remove double quotes from output string

core/PikaManager.py
... ... @@ -125,7 +125,7 @@ class PikaManager:
125 125 channel = self._setup_channel(self.conn_send)
126 126 if channel != None:
127 127 channel.queue_declare(queue = queue_name)
128   - channel.basic_publish(exchange = '', routing_key = queue_name, properties = pika.BasicProperties(correlation_id = props.correlation_id), body = json.dumps(body))
  128 + channel.basic_publish(exchange = '', routing_key = queue_name, properties = pika.BasicProperties(correlation_id = props.correlation_id), body = body)
129 129 channel.close()
130 130  
131 131 def receive_from_queue(self, queue_name, callback):
... ...
core/renderer.py
... ... @@ -176,8 +176,8 @@ def run(ch, method, properties, body):
176 176 except:
177 177 filesize = 0
178 178  
179   - body = {"file": properties.correlation_id+".mp4", "size": filesize, "status": "success"}
180   - json.dumps(body)
  179 + content = {"file": properties.correlation_id+".mp4", "size": filesize, "status": "success"}
  180 + body = json.dumps(content)
181 181  
182 182 manager.send_to_queue("videos", body, properties)
183 183  
... ...
translate-api/helpers/amqpManager.js
... ... @@ -58,7 +58,7 @@ exports.receiveFromQueue = function(id, queue, durability, res, next) {
58 58 ch.consume(queue, function(msg) {
59 59 if (msg.properties.correlationId === id) {
60 60 ch.ack(msg);
61   - next(null, msg.content.toString())
  61 + next(null, msg.content.toString());
62 62 try {
63 63 ch.close();
64 64 }
... ...