fixed major problem in scan

still troubleshooting weird %s error