Patch __find_records_by_ids

This prevents ActiveRecord errors due to missing records.