Bismihi ta'ala
It is haram to intentionally swallow blood, and so if you know you have blood in your mouth, you should spit it out. If you are in the state of prayer, and you taste blood, or for some reason you know you have blood in your mouth, you can spit it into a tissue and continue with your prayer, or wait until you finish your prayer, and then spit it out.
And Allah knows best.