Skip to content

Commit

Permalink
main: fix debuging
Browse files Browse the repository at this point in the history
  • Loading branch information
Ali Mihandoost committed Sep 28, 2015
1 parent 5674e73 commit b6a8391
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ onMessage = (msg) => {
let buildMessage = makeMessageObj(msg);
notifyAdmins('Debug: ' + JSON.stringify({sourceMessage: msg, buildMessage: buildMessage}, null, 2));
notifyAdmins(buildMessage);
notifyAdmins(buildMessage.id, buildMessage.from);
// notifyAdmins(buildMessage.id, buildMessage.from);
return;
}

Expand Down Expand Up @@ -248,7 +248,7 @@ onMessage = (msg) => {
if(!fromAdmin && !msg.new_chat_title && !msg.new_chat_participant && !msg.left_chat_participant && !msg.new_chat_photo && !msg.delete_chat_photo)
{
notifyAdmins('unknownMessage: ' + JSON.stringify(msg, null, 2));
notifyAdmins(msg.id);
notifyAdmins(msg.message_id, msg.from.id);
}
},

Expand Down Expand Up @@ -339,7 +339,7 @@ sendMessage = (id, message, fb) => {
let username = data.users[id] ?
data.users[id].username ? `@${data.users[id].username}` : `${data.users[id].title}`
: `#${id}`;
console.log(`sendMessage(${username}): message.id`);
console.log(`sendMessage(${username}): ${message.id}`);

let callBack = (err, data) => {
if (!err) return fb ? fb(data) : null;
Expand Down

0 comments on commit b6a8391

Please sign in to comment.