rusackas commented on a change in pull request #17427:
URL: https://github.com/apache/superset/pull/17427#discussion_r750952851



##########
File path: 
superset-frontend/src/explore/components/controls/MetricControl/AdhocMetric.js
##########
@@ -80,9 +80,9 @@ export default class AdhocMetric {
 
     this.optionName =
       adhocMetric.optionName ||
-      `metric_${Math.random()
+      `metric_${Math.random().toString(36).substring(2, 15)}_${Math.random()

Review comment:
       This logic is also used 
[here](https://github.com/apache/superset/pull/17427/files#diff-c3790e716d19041bf895c7134e1961907442bd0d8477d6e897f33517591832e9R124)
 - maybe we could abstract it to a shared utility




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to