Fix small bug in findnotes algo.