mirror of
https://github.com/nasa/openmct.git
synced 2024-12-21 22:17:49 +00:00
Use series.getDatum when available
This commit is contained in:
parent
c4d47ddc26
commit
6f257593c8
@ -122,9 +122,12 @@ define(
|
||||
*/
|
||||
self.getDatum = function (telemetryObject, index) {
|
||||
function makeNewDatum(series) {
|
||||
return series ?
|
||||
subscription.makeDatum(telemetryObject, series, index) :
|
||||
undefined;
|
||||
if (series) {
|
||||
if (series.getDatum) {
|
||||
return series.getDatum(index);
|
||||
}
|
||||
return subscription.makeDatum(telemetryObject, series, index);
|
||||
}
|
||||
}
|
||||
|
||||
return typeof index !== 'number' ?
|
||||
|
@ -45,6 +45,9 @@ define([
|
||||
};
|
||||
|
||||
function createDatum(domainObject, metadata, legacySeries, i) {
|
||||
if (legacySeries.getDatum) {
|
||||
return legacySeries.getDatum(i);
|
||||
}
|
||||
var datum = {};
|
||||
|
||||
metadata.domains.reduce(function (d, domain) {
|
||||
|
Loading…
Reference in New Issue
Block a user