(a) The proceeds of the sale of the contents shall be applied as follows:
(1) to the payment of fees and costs of the removal and sale;
(2) to payment of the allowances and costs of closing and keeping closed the buildings or places;
(3) to the payment of plaintiff's costs;
(4) to the payment of any balance remaining to the owner of the property sold.
(b) If the proceeds do not fully discharge all the costs, fees, and allowances, the premises may also be sold under execution issued upon the order of the court and the proceeds of the sale applied in like manner. However, the building or realty in which the nuisance is conducted or real estate on which it stands may not be subject to a lien, judgment, or costs unless the owner, or an agent or representative of the owner, has been duly served with process in the action and been given an opportunity to show good faith and to immediately abate the nuisance.