fixed error in ajax