aboutsummaryrefslogtreecommitdiff
path: root/db.go
diff options
context:
space:
mode:
Diffstat (limited to 'db.go')
-rw-r--r--db.go10
1 files changed, 1 insertions, 9 deletions
diff --git a/db.go b/db.go
index d15dc74..6b43f43 100644
--- a/db.go
+++ b/db.go
@@ -575,15 +575,7 @@ type Stats struct {
// This is useful when obtaining stats at two different points and time and
// you need the performance counters that occurred within that time span.
func (s *Stats) Sub(other *Stats) Stats {
- var diff Stats
- if s == nil {
- if other == nil {
- return diff
- } else {
- return *other
- }
- }
- diff = *s
+ var diff = *s
if other == nil {
return diff
}