try catch
This commit is contained in:
@@ -34,10 +34,14 @@ routes(app);
|
||||
|
||||
|
||||
kafka.consume("FLUTTER_PAYMENT_RECEIVED", (value) => {
|
||||
console.log("📨 Receive message xxxx: ", value);
|
||||
var obj = phpUnserialize(value);
|
||||
console.log(obj);
|
||||
console.log("📨 Receive message yyyy: ", obj.txRef);
|
||||
try {
|
||||
console.log("📨 Receive message xxxx: ", value);
|
||||
var obj = phpUnserialize(value);
|
||||
console.log(obj);
|
||||
console.log("📨 Receive message yyyy: ", obj.txRef);
|
||||
} catch (exceptionVar) {
|
||||
console.log("📨 Error ", exceptionVar.message);
|
||||
}
|
||||
});
|
||||
|
||||
app.listen(port, "0.0.0.0", function() {
|
||||
|
||||
Reference in New Issue
Block a user