Explore button: fix item name building

This commit is contained in:
Alexander Zobnin
2020-05-20 11:21:59 +03:00
parent cf578b7249
commit 3aaf58b05a
3 changed files with 5 additions and 5 deletions

View File

@@ -19,7 +19,7 @@ export const variableRegex = /\$(\w+)|\[\[([\s\S]+?)(?::(\w+))?\]\]|\${(\w+)(?:\
* @param {string} key item key, ie system.cpu.util[,system,avg1]
* @return {string} expanded name, ie "CPU system time"
*/
export function expandItemName(name, key) {
export function expandItemName(name: string, key: string): string {
// extract params from key:
// "system.cpu.util[,system,avg1]" --> ["", "system", "avg1"]