refactoring: enterprise build/hooks refactorings (#12478)

This commit is contained in:
Torkel Ödegaard
2018-07-02 04:33:39 -07:00
committed by GitHub
parent 2941dff428
commit b8724ae0c4
13 changed files with 73 additions and 55 deletions

View File

@@ -334,6 +334,14 @@ func updateTotalStats() {
var usageStatsURL = "https://stats.grafana.org/grafana-usage-report"
func getEdition() string {
if setting.IsEnterprise {
return "enterprise"
} else {
return "oss"
}
}
func sendUsageStats() {
if !setting.ReportingEnabled {
return
@@ -349,6 +357,7 @@ func sendUsageStats() {
"metrics": metrics,
"os": runtime.GOOS,
"arch": runtime.GOARCH,
"edition": getEdition(),
}
statsQuery := models.GetSystemStatsQuery{}