(1) This section applies where an agreement made in relation to a child is set aside under section 136.
(2) A court having jurisdiction under this Act may make such orders (including orders for the transfer of property) as it considers just and equitable for the purpose of preserving or adjusting the rights of the child or a party to the agreement.
(3) An order under subsection (2) may be made in the proceeding in which the agreement is set aside or in another proceeding brought on the application of a party to the agreement.
(4) In the exercise of its powers under this section, a court must have regard to the interests of, and must make any order proper for the protection of, a bona fide purchaser or other person interested.