fix scan and friends