Whenever relief is sought regarding any type of custody matter under this Act, the court, before granting relief, shall determine whether any order of protection has previously been entered in the instant proceeding or any other proceeding in which any party, or a child of any party, or both, if relevant, has been designated as either a respondent or a protected person.
705 ILCS 405/1-16