 The soldiers released al-Mu'tazz from his prison and acknowledged him as their caliph.Al-Mu'tazz agreed to the proposal and an oath of allegiance was drawn up; many of the officials in Samarra then swore allegiance to him.With two members of the Abbasid dynasty now claiming to be caliph, war became inevitable.