* during range, stop scanning earlier than currently scanning * refactor for better testing * clean up a different edge case