fix failing tests
This commit is contained in:
parent
041518e760
commit
b832b098ca
@ -1,5 +1,4 @@
|
||||
from saucebrush.filters import Filter
|
||||
from saucebrush.utils import FallbackCounter
|
||||
import collections
|
||||
import math
|
||||
|
||||
@ -202,10 +201,7 @@ class Histogram(StatsFilter):
|
||||
|
||||
def __init__(self, field, **kwargs):
|
||||
super(Histogram, self).__init__(field, **kwargs)
|
||||
if hasattr(collections, "Counter"):
|
||||
self._counter = collections.Counter()
|
||||
else:
|
||||
self._counter = FallbackCounter()
|
||||
self._counter = collections.Counter()
|
||||
|
||||
def process_field(self, item):
|
||||
self._counter[self.prep_field(item)] += 1
|
||||
|
Loading…
Reference in New Issue
Block a user