Skip to content

Commit

Permalink
Remove pointless function
Browse files Browse the repository at this point in the history
  • Loading branch information
bmario committed Oct 17, 2024
1 parent df0ef02 commit 88f40f8
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions src/MetricQWebView.js
Original file line number Diff line number Diff line change
Expand Up @@ -251,22 +251,15 @@ export function importMetricUrl () {
return false
}
const timeRanges = determineTimeRangeOfJsUrl(metricsObj)
initializeMetrics(metricsObj.cntr, timeRanges[0], timeRanges[1])
window.MetricQWebView.reinitialize(metricsObj.cntr, timeRanges[0], timeRanges[1])
return true
} else if (firstChar === '.') {
const splitted = jsurlStr.split('*')
if (splitted.length > 1) {
initializeMetrics(splitted.slice(2), splitted[0].substring(1), splitted[1])
window.MetricQWebView.reinitialize(splitted.slice(2), splitted[0].substring(1), splitted[1])
return true
}
}
}
return false
}

/* TODO: generalize this for cases where is no "legendApp" */
export function initializeMetrics (metricNamesArr, timeStart, timeStop) {
if (window.MetricQWebView) {
window.MetricQWebView.reinitialize(metricNamesArr, timeStart, timeStop)
}
}

0 comments on commit 88f40f8

Please sign in to comment.