I think it's good for you if the company hire you back as contract. It proves that your capability of your previous job. It's not your fault to get fired. Thus, it helps you to get UI.