When making a decision on the dissolution of a marriage, the court shall determine the amount of the state fee due either by one or both spouses when the civil registry office issues them a certificate of dissolution of marriage. Where the court finds it necessary to collect this fee from both spouses, it shall determine the amount of the fee due from each of them.