getHits method
Implementation
int getHits([String? key]) {
if (key == null || key.isEmpty) {
var counter = 0;
for (var i in logs.entries) {
if (i.key.contains(HitType.none.name)) {
counter = counter + i.value;
}
}
return counter;
} else {
return logs["$key-${HitType.none.name}"] ?? 0;
}
}