Whenever a petitioner shows that violations of the sanitary code will not be promptly remedied unless a receiver is appointed and the court determines that such appointment is in the best interest of occupants residing in the property, the court shall appoint a receiver of the property. Any receiver appointed under this paragraph may be removed by the court upon a showing that the receiver is not diligently carrying out the work necessary to bring the property into compliance with the code, or that it is in the best interest of any tenants residing in the property that removal occur.
No receiver shall be appointed until the receiver furnishes a bond or such other surety and provides proof of such liability insurance as the court deems sufficient in the circumstances of the case. Upon appointment, the receiver shall promptly repair the property and maintain it in a safe and healthful condition. The receiver shall have full power to borrow funds and to grant security interests or liens on the affected property, to make such contracts as the receiver may deem necessary, and, notwithstanding any special or general law to the contrary, shall not be subject to any public bidding law nor considered a state, county or municipal employee for any purpose. In order to secure payment of any costs incurred and repayment of any loans for repair, operation, maintenance or management of the property, the receiver shall have a lien with priority over all other liens or mortgages except municipal liens, and such lien priority may be assigned to lenders for the purpose of securing loans for repair, operation, maintenance or management of the property. No such lien shall be effective unless recorded in the registry for the county in which the property is located.