All penalties recovered by the State in any action pursuant to this chapter, together with the costs thereof, shall be paid into the State Treasury to the credit of the General Fund. Any such action may be compromised or discontinued on application of the commission upon such terms as the court approves and orders.