added a wfif scan function