Remove event code from searchForPics