fixed big in scanRight, fixed wrong type for idx, fixed removeOccurrence in doRepair