Browse Source

Remove unused code

Ask Bjørn Hansen 12 years ago
parent
commit
2b87a0fee6
1 changed files with 0 additions and 20 deletions
  1. 0 20
      monitor.go

+ 0 - 20
monitor.go

@@ -8,7 +8,6 @@ import (
 	"html/template"
 	"html/template"
 	"io"
 	"io"
 	"log"
 	"log"
-	"math"
 	"net/http"
 	"net/http"
 	"os"
 	"os"
 	"runtime"
 	"runtime"
@@ -241,21 +240,6 @@ func (s RatesByCount) Less(i, j int) bool {
 	return ic > jc
 	return ic > jc
 }
 }
 
 
-func round(val float64, prec int) float64 {
-
-	var rounder float64
-	intermed := val * math.Pow(10, float64(prec))
-
-	if val >= 0.5 {
-		rounder = math.Ceil(intermed)
-	} else {
-		rounder = math.Floor(intermed)
-	}
-
-	return rounder / math.Pow(10, float64(prec))
-
-}
-
 type histogramData struct {
 type histogramData struct {
 	Max    int64
 	Max    int64
 	Min    int64
 	Min    int64
@@ -290,10 +274,6 @@ func StatusServer(zones Zones) func(http.ResponseWriter, *http.Request) {
 			return
 			return
 		}
 		}
 
 
-		tmpl.Funcs(map[string]interface{}{
-			"round": round,
-		})
-
 		rates := make(Rates, 0)
 		rates := make(Rates, 0)
 
 
 		for name, zone := range zones {
 		for name, zone := range zones {