i dont think it should be a problem if your former employer is ready to give a exit permit and ur residence visa is still valid.