It is narrated from al-Hasan (may Allah have mercy on him) that the freeing of slaves is to be given precedence.