added error handling from papers search