Optionally log message send times on the client

(imported from commit 900a513496b7796173a7685a55b110b63024f574)
This commit is contained in:
Zev Benjamin 2013-10-21 16:29:33 -04:00
parent ff38b5fd95
commit 286803660f
2 changed files with 7 additions and 0 deletions

View File

@ -355,7 +355,11 @@ function send_message() {
request.to = JSON.stringify([request.to]);
}
var start_time = new Date();
function success() {
if (feature_flags.log_send_times) {
blueslip.log("send time: " + (new Date() - start_time));
}
$("#new_message_content").val('').focus();
autosize_textarea();
$("#send-status").hide(0);

View File

@ -17,6 +17,9 @@ var customer4_realms = [
];
var is_customer4 = _.contains(customer4_realms, page_params.domain);
// Manually-flipped debugging flags
exports.log_send_times = false;
// Permanent realm-specific stuff:
exports.twenty_four_hour_time = internal_24_hour_people || iceland;