Skip to content
This repository was archived by the owner on Mar 19, 2021. It is now read-only.

Commit ddf616e

Browse files
authored
Merge pull request #15 from grafana/fix_legacy_slugify
remove legacy slugify functions
2 parents 193d94c + b228072 commit ddf616e

24 files changed

+36
-134
lines changed

dist/components/clusters/clusterInfo.js

Lines changed: 2 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/components/clusters/clusterInfo.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/components/clusters/clusterInfo.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,6 @@
33
import _ from 'lodash';
44
import $ from 'jquery';
55

6-
function slugify(str) {
7-
var slug = str.replace("@", "at").replace("&", "and").replace(/[.]/g, "_").replace("/\W+/", "");
8-
return slug;
9-
}
10-
116
export class ClusterInfoCtrl {
127
cluster: any;
138
pageReady: boolean;
@@ -96,7 +91,7 @@ export class ClusterInfoCtrl {
9691
.search({
9792
"var-datasource": this.cluster.jsonData.ds,
9893
"var-cluster": this.cluster.name,
99-
"var-node": node === 'All' ? 'All': slugify(node.metadata.name)
94+
"var-node": node === 'All' ? 'All': node.metadata.name
10095
});
10196
}
10297
}
@@ -107,7 +102,7 @@ export class ClusterInfoCtrl {
107102
this.$location.path("plugins/grafana-kubernetes-app/page/cluster-workloads")
108103
.search({
109104
"cluster": this.cluster.id,
110-
"namespace": slugify(ns.metadata.name)
105+
"namespace": ns.metadata.name
111106
});
112107
}
113108
}

dist/components/clusters/clusterWorkloads.js

Lines changed: 2 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)