revamp algorithm, removes spurious entries
version bump @2.2.0