function pushMessagesToTopOfLogsTable(pageId) {
  let logsTable = $('message-logs-table');
  let currentMessageRow = window.logTableMap[pageId];

  // Moving empty row.
  let emptyRow = logsTable.rows[currentMessageRow.rowIndex + 2];
  pushRowToTopOfLogsTable(emptyRow, logsTable);

  // Moving expansion row.
  let expansionRow = logsTable.rows[currentMessageRow.rowIndex + 1];
  pushRowToTopOfLogsTable(expansionRow, logsTable);

  // Moving the original row.
  pushRowToTopOfLogsTable(currentMessageRow, logsTable);
  window.logTableMap[pageId] = logsTable.rows[1];
}
/**
 * Helper method to move a group of messages to the top of the Logs Table,
 * including the expansion row corresponding to the |pageId|.
 *
 * @param {number} pageId The key of |logTableMap| of the moving row.
 */
Helper method to move a group of messages to the top of the Logs Table,
including the expansion row corresponding to the |pageId|.

@param {number} pageId The key of |logTableMap| of the moving row.
Helper method to move a group of messages to the top of the Logs Table including the expansion row corresponding to the |pageId| . @param { number } pageId The key of |logTableMap| of the moving row .
function pushMessagesToTopOfLogsTable(pageId) {
  let logsTable = $('message-logs-table');
  let currentMessageRow = window.logTableMap[pageId];
  let emptyRow = logsTable.rows[currentMessageRow.rowIndex + 2];
  pushRowToTopOfLogsTable(emptyRow, logsTable);
  let expansionRow = logsTable.rows[currentMessageRow.rowIndex + 1];
  pushRowToTopOfLogsTable(expansionRow, logsTable);
  pushRowToTopOfLogsTable(currentMessageRow, logsTable);
  window.logTableMap[pageId] = logsTable.rows[1];
}
function pushMessagesToTopOfLogsTable ( pageId ) { let logsTable = $ ( 'message-logs-table' ) ; let currentMessageRow = window . logTableMap [ pageId ] ; let emptyRow = logsTable . rows [ currentMessageRow . rowIndex + 2 ] ; pushRowToTopOfLogsTable ( emptyRow , logsTable ) ; let expansionRow = logsTable . rows [ currentMessageRow . rowIndex + 1 ] ; pushRowToTopOfLogsTable ( expansionRow , logsTable ) ; pushRowToTopOfLogsTable ( currentMessageRow , logsTable ) ; window . logTableMap [ pageId ] = logsTable . rows [ 1 ] ; }
Helper method to move a group of messages to the top of the Logs Table,
 including the expansion row corresponding to the |pageId|.
Helper method to move a group of messages to the top of the Logs Table including the expansion row corresponding to the |pageId| .
// Moving empty row. // Moving expansion row. // Moving the original row.