mirror of
https://github.com/nasa/openmct.git
synced 2025-01-18 18:57:01 +00:00
#769 - Removed empty code block and addressed some excessive guard code
This commit is contained in:
parent
6322964dec
commit
aac5a6d250
@ -140,8 +140,7 @@ define(
|
|||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
TableConfiguration.prototype.defaultColumnConfiguration = function () {
|
TableConfiguration.prototype.defaultColumnConfiguration = function () {
|
||||||
return ((this.domainObject.getModel().configuration || {}).table ||
|
return ((this.domainObject.getModel().configuration || {}).table || {}).columns || {};
|
||||||
{}).columns;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -176,7 +175,7 @@ define(
|
|||||||
TableConfiguration.prototype.buildColumnConfiguration = function () {
|
TableConfiguration.prototype.buildColumnConfiguration = function () {
|
||||||
var configuration = {},
|
var configuration = {},
|
||||||
//Use existing persisted config, or default it
|
//Use existing persisted config, or default it
|
||||||
defaultConfig = this.defaultColumnConfiguration() || {};
|
defaultConfig = this.defaultColumnConfiguration();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* For each column header, define a configuration value
|
* For each column header, define a configuration value
|
||||||
@ -185,7 +184,7 @@ define(
|
|||||||
*/
|
*/
|
||||||
this.getHeaders().forEach(function (columnTitle) {
|
this.getHeaders().forEach(function (columnTitle) {
|
||||||
configuration[columnTitle] =
|
configuration[columnTitle] =
|
||||||
typeof (defaultConfig || {})[columnTitle] === 'undefined' ? true :
|
typeof defaultConfig[columnTitle] === 'undefined' ? true :
|
||||||
defaultConfig[columnTitle];
|
defaultConfig[columnTitle];
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -421,9 +421,7 @@ define(
|
|||||||
currentColumnLength,
|
currentColumnLength,
|
||||||
largestColumn,
|
largestColumn,
|
||||||
largestColumnLength;
|
largestColumnLength;
|
||||||
if (!row[key]){
|
if (row[key]){
|
||||||
//do nothing, no value for this column;
|
|
||||||
} else {
|
|
||||||
currentColumn = (row[key]).text;
|
currentColumn = (row[key]).text;
|
||||||
currentColumnLength =
|
currentColumnLength =
|
||||||
(currentColumn && currentColumn.length) ?
|
(currentColumn && currentColumn.length) ?
|
||||||
|
Loading…
Reference in New Issue
Block a user