Any bloody vomit or tarry poop should be considered an emergency. You should go to the emergency vet at once. You are lucky this time. Next time maybe not
Not trying to be a know it all, I'm an RN and have seen too many human problems like this. I agree that you should go to the vet asap for a check up.