Fix whitespace with "make format".

This commit is contained in:
Julius Volz 2013-01-18 00:07:00 +01:00
parent 86e5edc7fe
commit a20bf35997
5 changed files with 64 additions and 65 deletions

View file

@ -48,7 +48,7 @@ func (serv MetricsService) QueryRange(Expr string, End int64, Range int64, Step
Step = 1
}
if End - Range < 0 {
if End-Range < 0 {
Range = End
}
@ -57,9 +57,9 @@ func (serv MetricsService) QueryRange(Expr string, End int64, Range int64, Step
matrix := ast.EvalVectorRange(
exprNode.(ast.VectorNode),
time.Unix(End - Range, 0),
time.Unix(End-Range, 0),
time.Unix(End, 0),
time.Duration(Step) * time.Second)
time.Duration(Step)*time.Second)
sort.Sort(matrix)
return ast.TypedValueToJSON(matrix, "matrix")

View file

@ -14,8 +14,8 @@
package model
import (
"time"
"fmt"
"time"
)
// A Fingerprint is a simplified representation of an entity---e.g., a hash of

View file

@ -537,7 +537,6 @@ func (matrix Matrix) Swap(i, j int) {
matrix[i], matrix[j] = matrix[j], matrix[i]
}
func (node *StringLiteral) Eval(timestamp *time.Time) string {
return node.str
}