Skip to content

Commit

Permalink
null-check cat_technology
Browse files Browse the repository at this point in the history
  • Loading branch information
cproof committed Jan 3, 2024
1 parent f736381 commit 203655f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/Opentest.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,10 @@ function printTestData(testdata, target) {
ODF.classificationFormatter((testdata.ping_ms === null)?null:(testdata.ping_ms).formatNumber(getSignificantDigits(testdata.ping_ms)), "ping_shortest", testdata.ping_classification, 'ms', 'ping');

//special case, if both signal_strength and lte_rsrp are set
if (testdata.signal_strength && testdata.lte_rsrp) {
if (testdata.signal_strength && testdata.lte_rsrp && testdata.cat_technology !== null) {
ODF.classificationFormatter(testdata.lte_rsrp, "lte_rsrp", testdata.signal_classification, 'dBm', testdata.cat_technology.toLowerCase());
}
else if (testdata.signal_strength || testdata.lte_rsrp) {
else if ((testdata.signal_strength || testdata.lte_rsrp) && testdata.cat_technology !== null) {
//lte
ODF.classificationFormatter(testdata.lte_rsrp, "signal_strength", testdata.signal_classification, 'dBm', testdata.cat_technology.toLowerCase());
}
Expand Down

0 comments on commit 203655f

Please sign in to comment.