提交 d87d14e6 编写于 作者: G gusreiber

PR-2046:moving generalRow declaration inside if

上级 e39b2ab0
......@@ -48,13 +48,13 @@ exports.fromConfigTable = function(configTable) {
// calling it a "General" section. We do this by marking the first row in the table.
// See the next block of code.
var generalRow = $('<tr class="section-header-row insert first" title="General"><td colspan="4"><div class="section-header"><a class="section-anchor">#</a>General</div></td></tr>');
if(!firstRow.hasClass('section-header-row')){
firstRow.before(generalRow);
firstRow = configTableMetadata.getFirstRow();
var newArray = $.makeArray(topRows);
newArray.unshift(generalRow[0]);
topRows = $(newArray);
var generalRow = $('<tr class="section-header-row insert first" title="General"><td colspan="4"><div class="section-header"><a class="section-anchor">#</a>General</div></td></tr>');
firstRow.before(generalRow);
firstRow = configTableMetadata.getFirstRow();
var newArray = $.makeArray(topRows);
newArray.unshift(generalRow[0]);
topRows = $(newArray);
}
firstRow.addClass('section-header-row');
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册