fix bugs in server.R to deal with fetch ref from Pubmed